From 203de509d2693d550ae19d447a2ce597e6dd3b63 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 14:03:09 -0300 Subject: [PATCH 01/29] Add AutomationReceiver to compilation scripts and generated wrappers - Updated the native_solc_compile_all_automation script to include AutomationReceiver. - Modified go_generate_automation.go to generate wrapper for AutomationReceiver. - Updated generated-wrapper-dependency-versions-do-not-edit.txt to include AutomationReceiver dependencies. --- .../native_solc_compile_all_automation | 1 + .../v0.8/automation/AutomationReceiver.sol | 68 + contracts/src/v0.8/automation/IReceiver.sol | 15 + .../src/v0.8/automation/ReceiverTemplate.sol | 142 ++ .../automation_receiver.go | 1786 +++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + gethwrappers/go_generate_automation.go | 1 + 7 files changed, 2014 insertions(+) create mode 100644 contracts/src/v0.8/automation/AutomationReceiver.sol create mode 100644 contracts/src/v0.8/automation/IReceiver.sol create mode 100644 contracts/src/v0.8/automation/ReceiverTemplate.sol create mode 100644 gethwrappers/generated/automation_receiver/automation_receiver.go diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation index 369ef54e0b..a4cf975cf7 100755 --- a/contracts/scripts/native_solc_compile_all_automation +++ b/contracts/scripts/native_solc_compile_all_automation @@ -63,3 +63,4 @@ compileContract automation-compile-23 upkeeps/EthBalanceMonitor compileContract automation-compile-23 v2_3/AutomationUtils2_3 compileContract automation-compile-23 interfaces/v2_3/IAutomationRegistryMaster2_3 compileContract automation-compile-23 testhelpers/MockETHUSDAggregator +compileContract automation-compile-23 AutomationReceiver diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol new file mode 100644 index 0000000000..615531d854 --- /dev/null +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -0,0 +1,68 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {ReceiverTemplate} from "./ReceiverTemplate.sol"; + +/** + * @title AutomationReceiver + * @notice Generic bridge that executes Automation-style upkeeps delivered by a CRE workflow. + * + * @dev Two independent authorization layers protect this contract: + * + * 1. INBOUND (inherited from {ReceiverTemplate}) — answers "who may deliver a report?": + * the CRE Forwarder address plus the optional workflowId / workflowName / workflowOwner + * identity checks. + * + * 2. OUTBOUND (this contract) — answers "what may a report make this contract do?": + * a closed-by-default allowlist of (target, function-selector) pairs. The owner must + * explicitly allow each (target, selector) before it can be executed. + * + * Migration rule of thumb: inbound authorizes the workflow; outbound authorizes the action. + */ +contract AutomationReceiver is ReceiverTemplate { + mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; + + event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); + event CallFailed(address indexed target, bytes4 indexed selector, bytes reason); + event CallAllowedSet(address indexed target, bytes4 indexed selector, bool allowed); + + error InvalidTargetAddress(); + error MissingSelector(); + error CallNotAllowed(address target, bytes4 selector); + + constructor(address _forwarder) ReceiverTemplate(_forwarder) {} + + /// @notice Allow or disallow the receiver to call `selector` on `target`. Owner-only. + function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { + if (target == address(0)) revert InvalidTargetAddress(); + s_callAllowed[target][selector] = allowed; + emit CallAllowedSet(target, selector, allowed); + } + + /// @notice Returns whether the receiver may call `selector` on `target`. + function isCallAllowed(address target, bytes4 selector) external view returns (bool) { + return s_callAllowed[target][selector]; + } + + /// @notice Decodes and executes the call encoded in the CRE report. + /// @param report ABI-encoded (address target, bytes data). + function _processReport(bytes calldata report) internal override { + (address target, bytes memory data) = abi.decode(report, (address, bytes)); + + if (target == address(0)) revert InvalidTargetAddress(); + if (data.length < 4) revert MissingSelector(); + + bytes4 selector; + assembly { + selector := mload(add(data, 0x20)) + } + if (!s_callAllowed[target][selector]) revert CallNotAllowed(target, selector); + + (bool success, bytes memory returnData) = target.call(data); + if (success) { + emit CallExecuted(target, selector, returnData); + } else { + emit CallFailed(target, selector, returnData); + } + } +} diff --git a/contracts/src/v0.8/automation/IReceiver.sol b/contracts/src/v0.8/automation/IReceiver.sol new file mode 100644 index 0000000000..b427f81f5b --- /dev/null +++ b/contracts/src/v0.8/automation/IReceiver.sol @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IERC165} from "../vendor/IERC165.sol"; + +/// @title IReceiver - receives keystone reports +/// @notice Implementations must support the IReceiver interface through ERC165. +interface IReceiver is IERC165 { + /// @notice Handles incoming keystone reports. + /// @dev If this function call reverts, it can be retried with a higher gas + /// limit. The receiver is responsible for discarding stale reports. + /// @param metadata Report's metadata. + /// @param report Workflow report. + function onReport(bytes calldata metadata, bytes calldata report) external; +} diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol new file mode 100644 index 0000000000..908ed51dd9 --- /dev/null +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -0,0 +1,142 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IERC165} from "../vendor/IERC165.sol"; +import {IReceiver} from "./IReceiver.sol"; +import {Ownable} from "@openzeppelin/contracts@4.8.3/access/Ownable.sol"; + +/// @title ReceiverTemplate - Abstract receiver with optional permission controls +/// @notice Provides flexible, updatable security checks for receiving workflow reports +/// @dev The forwarder address is required at construction time for security. +/// Additional permission fields can be configured using setter functions. +abstract contract ReceiverTemplate is IReceiver, Ownable { + address private s_forwarderAddress; + + address private s_expectedAuthor; + bytes10 private s_expectedWorkflowName; + bytes32 private s_expectedWorkflowId; + + bytes private constant HEX_CHARS = "0123456789abcdef"; + + error InvalidForwarderAddress(); + error InvalidSender(address sender, address expected); + error InvalidAuthor(address received, address expected); + error InvalidWorkflowName(bytes10 received, bytes10 expected); + error InvalidWorkflowId(bytes32 received, bytes32 expected); + error WorkflowNameRequiresAuthorValidation(); + + event ForwarderAddressUpdated(address indexed previousForwarder, address indexed newForwarder); + event ExpectedAuthorUpdated(address indexed previousAuthor, address indexed newAuthor); + event ExpectedWorkflowNameUpdated(bytes10 indexed previousName, bytes10 indexed newName); + event ExpectedWorkflowIdUpdated(bytes32 indexed previousId, bytes32 indexed newId); + event SecurityWarning(string message); + + constructor(address _forwarderAddress) Ownable() { + if (_forwarderAddress == address(0)) revert InvalidForwarderAddress(); + s_forwarderAddress = _forwarderAddress; + emit ForwarderAddressUpdated(address(0), _forwarderAddress); + } + + function getForwarderAddress() external view returns (address) { + return s_forwarderAddress; + } + + function getExpectedAuthor() external view returns (address) { + return s_expectedAuthor; + } + + function getExpectedWorkflowName() external view returns (bytes10) { + return s_expectedWorkflowName; + } + + function getExpectedWorkflowId() external view returns (bytes32) { + return s_expectedWorkflowId; + } + + /// @inheritdoc IReceiver + function onReport(bytes calldata metadata, bytes calldata report) external override { + if (s_forwarderAddress != address(0) && msg.sender != s_forwarderAddress) { + revert InvalidSender(msg.sender, s_forwarderAddress); + } + + if (s_expectedWorkflowId != bytes32(0) || s_expectedAuthor != address(0) || s_expectedWorkflowName != bytes10(0)) { + (bytes32 workflowId, bytes10 workflowName, address workflowOwner) = _decodeMetadata(metadata); + + if (s_expectedWorkflowId != bytes32(0) && workflowId != s_expectedWorkflowId) { + revert InvalidWorkflowId(workflowId, s_expectedWorkflowId); + } + if (s_expectedAuthor != address(0) && workflowOwner != s_expectedAuthor) { + revert InvalidAuthor(workflowOwner, s_expectedAuthor); + } + if (s_expectedWorkflowName != bytes10(0)) { + if (s_expectedAuthor == address(0)) revert WorkflowNameRequiresAuthorValidation(); + if (workflowName != s_expectedWorkflowName) revert InvalidWorkflowName(workflowName, s_expectedWorkflowName); + } + } + + _processReport(report); + } + + function setForwarderAddress(address _forwarder) external onlyOwner { + address previousForwarder = s_forwarderAddress; + if (_forwarder == address(0)) emit SecurityWarning("Forwarder address set to zero - contract is now INSECURE"); + s_forwarderAddress = _forwarder; + emit ForwarderAddressUpdated(previousForwarder, _forwarder); + } + + function setExpectedAuthor(address _author) external onlyOwner { + address previousAuthor = s_expectedAuthor; + s_expectedAuthor = _author; + emit ExpectedAuthorUpdated(previousAuthor, _author); + } + + function setExpectedWorkflowName(string calldata _name) external onlyOwner { + bytes10 previousName = s_expectedWorkflowName; + if (bytes(_name).length == 0) { + s_expectedWorkflowName = bytes10(0); + emit ExpectedWorkflowNameUpdated(previousName, bytes10(0)); + return; + } + bytes32 hash = sha256(bytes(_name)); + bytes memory hexString = _bytesToHexString(abi.encodePacked(hash)); + bytes memory first10 = new bytes(10); + for (uint256 i = 0; i < 10; i++) { + first10[i] = hexString[i]; + } + s_expectedWorkflowName = bytes10(first10); + emit ExpectedWorkflowNameUpdated(previousName, s_expectedWorkflowName); + } + + function setExpectedWorkflowId(bytes32 _id) external onlyOwner { + bytes32 previousId = s_expectedWorkflowId; + s_expectedWorkflowId = _id; + emit ExpectedWorkflowIdUpdated(previousId, _id); + } + + function _bytesToHexString(bytes memory data) private pure returns (bytes memory) { + bytes memory hexString = new bytes(data.length * 2); + for (uint256 i = 0; i < data.length; i++) { + hexString[i * 2] = HEX_CHARS[uint8(data[i] >> 4)]; + hexString[i * 2 + 1] = HEX_CHARS[uint8(data[i] & 0x0f)]; + } + return hexString; + } + + function _decodeMetadata( + bytes memory metadata + ) internal pure returns (bytes32 workflowId, bytes10 workflowName, address workflowOwner) { + assembly { + workflowId := mload(add(metadata, 32)) + workflowName := mload(add(metadata, 64)) + workflowOwner := shr(mul(12, 8), mload(add(metadata, 74))) + } + return (workflowId, workflowName, workflowOwner); + } + + function _processReport(bytes calldata report) internal virtual; + + /// @inheritdoc IERC165 + function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { + return interfaceId == type(IReceiver).interfaceId || interfaceId == type(IERC165).interfaceId; + } +} diff --git a/gethwrappers/generated/automation_receiver/automation_receiver.go b/gethwrappers/generated/automation_receiver/automation_receiver.go new file mode 100644 index 0000000000..30002b1ed1 --- /dev/null +++ b/gethwrappers/generated/automation_receiver/automation_receiver.go @@ -0,0 +1,1786 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package automation_receiver + +import ( + "errors" + "fmt" + "math/big" + "strings" + + ethereum "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/event" + "github.com/smartcontractkit/chainlink-evm/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var AutomationReceiverMetaData = &bind.MetaData{ + ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", + Bin: "0x608060405234801561001057600080fd5b5060405162001a2738038062001a2783398101604081905261003191610101565b8061003b336100b1565b6001600160a01b0381166100615760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040516000907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a35050610131565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561011357600080fd5b81516001600160a01b038116811461012a57600080fd5b9392505050565b6118e680620001416000396000f3fe608060405234801561001057600080fd5b50600436106100f55760003560e01c80639c1c77ca11610097578063d60c884b11610066578063d60c884b146102ac578063d777cc6d146102bf578063f2fde38b146102d2578063f5c793ef146102e557600080fd5b80639c1c77ca14610224578063a619d81814610237578063bc1fc27a14610286578063c3c44ac21461029957600080fd5b8063715018a6116100d3578063715018a61461017f578063797c8d6914610189578063805f2132146101f35780638da5cb5b1461020657600080fd5b806301ffc9a7146100fa5780633397cf67146101225780633441856f14610161575b600080fd5b61010d61010836600461140a565b6102f6565b60405190151581526020015b60405180910390f35b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610119565b60015473ffffffffffffffffffffffffffffffffffffffff1661013c565b61018761038f565b005b61010d61019736600461144e565b73ffffffffffffffffffffffffffffffffffffffff821660009081526004602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101876102013660046114cc565b6103a3565b60005473ffffffffffffffffffffffffffffffffffffffff1661013c565b610187610232366004611538565b610765565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff000000000000000000000000000000000000000000009091168152602001610119565b610187610294366004611586565b610874565b6101876102a73660046115c8565b610af6565b6101876102ba3660046115e1565b610b37565b6101876102cd3660046115e1565b610bb6565b6101876102e03660046115e1565b610ce4565b600354604051908152602001610119565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f805f213200000000000000000000000000000000000000000000000000000000148061038957507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b610397610d9b565b6103a16000610e1c565b565b60015473ffffffffffffffffffffffffffffffffffffffff16158015906103e2575060015473ffffffffffffffffffffffffffffffffffffffff163314155b15610440576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b600354151580610467575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806104b0575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b156107555760008060006104f987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e9192505050565b60035492955090935091501580159061051457506003548314155b15610559576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610437918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff161580159061059b575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b156105f6576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610437565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016156107515760025473ffffffffffffffffffffffffffffffffffffffff1661068a576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610751576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610437565b5050505b61075f8282610eaa565b50505050565b61076d610d9b565b73ffffffffffffffffffffffffffffffffffffffff83166107ba576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff831660008181526004602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b61087c610d9b565b60025474010000000000000000000000000000000000000000900460b01b600082900361091f57600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040516000907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b6000600284846040516109339291906115fe565b602060405180830381855afa158015610950573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610973919061160e565b905060006109a18260405160200161098d91815260200190565b604051602081830303815290604052611178565b60408051600a8082528183019092529192506000919060208201818036833701905050905060005b600a811015610a42578281815181106109e4576109e4611656565b602001015160f81c60f81b828281518110610a0157610a01611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080610a3a816116b4565b9150506109c9565b50610a4c816116ec565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa590600090a3505050505050565b610afe610d9b565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b0390600090a35050565b610b3f610d9b565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad3190600090a35050565b610bbe610d9b565b60015473ffffffffffffffffffffffffffffffffffffffff908116908216610c6e577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7604051610c659060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e90600090a35050565b610cec610d9b565b73ffffffffffffffffffffffffffffffffffffffff8116610d8f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610437565b610d9881610e1c565b50565b60005473ffffffffffffffffffffffffffffffffffffffff1633146103a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610437565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b600080610eb98385018561173c565b909250905073ffffffffffffffffffffffffffffffffffffffff8216610f0b576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015610f47576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff841660009081526004835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff16611018576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610437565b6000808473ffffffffffffffffffffffffffffffffffffffff16846040516110409190611842565b6000604051808303816000865af19150503d806000811461107d576040519150601f19603f3d011682016040523d82523d6000602084013e611082565b606091505b5091509150811561110057827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb884836040516110f3919061185e565b60405180910390a361116f565b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b683604051611166919061185e565b60405180910390a35b50505050505050565b606060008251600261118a91906118af565b67ffffffffffffffff8111156111a2576111a2611627565b6040519080825280601f01601f1916602001820160405280156111cc576020820181803683370190505b50905060005b83518110156113ce576040518060400160405280601081526020017f3031323334353637383961626364656600000000000000000000000000000000815250600485838151811061122557611225611656565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c90811061126557611265611656565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826112988360026118af565b815181106112a8576112a8611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506040518060400160405280601081526020017f303132333435363738396162636465660000000000000000000000000000000081525084828151811061131f5761131f611656565b602091010151815160f89190911c600f1690811061133f5761133f611656565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826113728360026118af565b61137d9060016118c6565b8151811061138d5761138d611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806113c6816116b4565b9150506111d2565b5092915050565b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461140557600080fd5b919050565b60006020828403121561141c57600080fd5b611425826113d5565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81168114610d9857600080fd5b6000806040838503121561146157600080fd5b823561146c8161142c565b915061147a602084016113d5565b90509250929050565b60008083601f84011261149557600080fd5b50813567ffffffffffffffff8111156114ad57600080fd5b6020830191508360208285010111156114c557600080fd5b9250929050565b600080600080604085870312156114e257600080fd5b843567ffffffffffffffff808211156114fa57600080fd5b61150688838901611483565b9096509450602087013591508082111561151f57600080fd5b5061152c87828801611483565b95989497509550505050565b60008060006060848603121561154d57600080fd5b83356115588161142c565b9250611566602085016113d5565b91506040840135801515811461157b57600080fd5b809150509250925092565b6000806020838503121561159957600080fd5b823567ffffffffffffffff8111156115b057600080fd5b6115bc85828601611483565b90969095509350505050565b6000602082840312156115da57600080fd5b5035919050565b6000602082840312156115f357600080fd5b81356114258161142c565b8183823760009101908152919050565b60006020828403121561162057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036116e5576116e5611685565b5060010190565b6000815160208301517fffffffffffffffffffff000000000000000000000000000000000000000000008082169350600a83101561173457808184600a0360031b1b83161693505b505050919050565b6000806040838503121561174f57600080fd5b823561175a8161142c565b9150602083013567ffffffffffffffff8082111561177757600080fd5b818501915085601f83011261178b57600080fd5b81358181111561179d5761179d611627565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156117e3576117e3611627565b816040528281528860208487010111156117fc57600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60005b83811015611839578181015183820152602001611821565b50506000910152565b6000825161185481846020870161181e565b9190910192915050565b602081526000825180602084015261187d81604085016020870161181e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b808202811582820484141761038957610389611685565b808201808211156103895761038961168556fea164736f6c6343000813000a", +} + +var AutomationReceiverABI = AutomationReceiverMetaData.ABI + +var AutomationReceiverBin = AutomationReceiverMetaData.Bin + +func DeployAutomationReceiver(auth *bind.TransactOpts, backend bind.ContractBackend, _forwarder common.Address) (common.Address, *types.Transaction, *AutomationReceiver, error) { + parsed, err := AutomationReceiverMetaData.GetAbi() + if err != nil { + return common.Address{}, nil, nil, err + } + if parsed == nil { + return common.Address{}, nil, nil, errors.New("GetABI returned nil") + } + + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(AutomationReceiverBin), backend, _forwarder) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &AutomationReceiver{address: address, abi: *parsed, AutomationReceiverCaller: AutomationReceiverCaller{contract: contract}, AutomationReceiverTransactor: AutomationReceiverTransactor{contract: contract}, AutomationReceiverFilterer: AutomationReceiverFilterer{contract: contract}}, nil +} + +type AutomationReceiver struct { + address common.Address + abi abi.ABI + AutomationReceiverCaller + AutomationReceiverTransactor + AutomationReceiverFilterer +} + +type AutomationReceiverCaller struct { + contract *bind.BoundContract +} + +type AutomationReceiverTransactor struct { + contract *bind.BoundContract +} + +type AutomationReceiverFilterer struct { + contract *bind.BoundContract +} + +type AutomationReceiverSession struct { + Contract *AutomationReceiver + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type AutomationReceiverCallerSession struct { + Contract *AutomationReceiverCaller + CallOpts bind.CallOpts +} + +type AutomationReceiverTransactorSession struct { + Contract *AutomationReceiverTransactor + TransactOpts bind.TransactOpts +} + +type AutomationReceiverRaw struct { + Contract *AutomationReceiver +} + +type AutomationReceiverCallerRaw struct { + Contract *AutomationReceiverCaller +} + +type AutomationReceiverTransactorRaw struct { + Contract *AutomationReceiverTransactor +} + +func NewAutomationReceiver(address common.Address, backend bind.ContractBackend) (*AutomationReceiver, error) { + abi, err := abi.JSON(strings.NewReader(AutomationReceiverABI)) + if err != nil { + return nil, err + } + contract, err := bindAutomationReceiver(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &AutomationReceiver{address: address, abi: abi, AutomationReceiverCaller: AutomationReceiverCaller{contract: contract}, AutomationReceiverTransactor: AutomationReceiverTransactor{contract: contract}, AutomationReceiverFilterer: AutomationReceiverFilterer{contract: contract}}, nil +} + +func NewAutomationReceiverCaller(address common.Address, caller bind.ContractCaller) (*AutomationReceiverCaller, error) { + contract, err := bindAutomationReceiver(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &AutomationReceiverCaller{contract: contract}, nil +} + +func NewAutomationReceiverTransactor(address common.Address, transactor bind.ContractTransactor) (*AutomationReceiverTransactor, error) { + contract, err := bindAutomationReceiver(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &AutomationReceiverTransactor{contract: contract}, nil +} + +func NewAutomationReceiverFilterer(address common.Address, filterer bind.ContractFilterer) (*AutomationReceiverFilterer, error) { + contract, err := bindAutomationReceiver(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &AutomationReceiverFilterer{contract: contract}, nil +} + +func bindAutomationReceiver(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := AutomationReceiverMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_AutomationReceiver *AutomationReceiverRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationReceiver.Contract.AutomationReceiverCaller.contract.Call(opts, result, method, params...) +} + +func (_AutomationReceiver *AutomationReceiverRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationReceiver.Contract.AutomationReceiverTransactor.contract.Transfer(opts) +} + +func (_AutomationReceiver *AutomationReceiverRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationReceiver.Contract.AutomationReceiverTransactor.contract.Transact(opts, method, params...) +} + +func (_AutomationReceiver *AutomationReceiverCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationReceiver.Contract.contract.Call(opts, result, method, params...) +} + +func (_AutomationReceiver *AutomationReceiverTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationReceiver.Contract.contract.Transfer(opts) +} + +func (_AutomationReceiver *AutomationReceiverTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationReceiver.Contract.contract.Transact(opts, method, params...) +} + +func (_AutomationReceiver *AutomationReceiverCaller) GetExpectedAuthor(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getExpectedAuthor") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetExpectedAuthor() (common.Address, error) { + return _AutomationReceiver.Contract.GetExpectedAuthor(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetExpectedAuthor() (common.Address, error) { + return _AutomationReceiver.Contract.GetExpectedAuthor(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) GetExpectedWorkflowId(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getExpectedWorkflowId") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetExpectedWorkflowId() ([32]byte, error) { + return _AutomationReceiver.Contract.GetExpectedWorkflowId(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetExpectedWorkflowId() ([32]byte, error) { + return _AutomationReceiver.Contract.GetExpectedWorkflowId(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) GetExpectedWorkflowName(opts *bind.CallOpts) ([10]byte, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getExpectedWorkflowName") + + if err != nil { + return *new([10]byte), err + } + + out0 := *abi.ConvertType(out[0], new([10]byte)).(*[10]byte) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetExpectedWorkflowName() ([10]byte, error) { + return _AutomationReceiver.Contract.GetExpectedWorkflowName(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetExpectedWorkflowName() ([10]byte, error) { + return _AutomationReceiver.Contract.GetExpectedWorkflowName(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) GetForwarderAddress(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getForwarderAddress") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetForwarderAddress() (common.Address, error) { + return _AutomationReceiver.Contract.GetForwarderAddress(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetForwarderAddress() (common.Address, error) { + return _AutomationReceiver.Contract.GetForwarderAddress(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) IsCallAllowed(opts *bind.CallOpts, target common.Address, selector [4]byte) (bool, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "isCallAllowed", target, selector) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) IsCallAllowed(target common.Address, selector [4]byte) (bool, error) { + return _AutomationReceiver.Contract.IsCallAllowed(&_AutomationReceiver.CallOpts, target, selector) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) IsCallAllowed(target common.Address, selector [4]byte) (bool, error) { + return _AutomationReceiver.Contract.IsCallAllowed(&_AutomationReceiver.CallOpts, target, selector) +} + +func (_AutomationReceiver *AutomationReceiverCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "owner") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) Owner() (common.Address, error) { + return _AutomationReceiver.Contract.Owner(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) Owner() (common.Address, error) { + return _AutomationReceiver.Contract.Owner(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "supportsInterface", interfaceId) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "onReport", metadata, report) +} + +func (_AutomationReceiver *AutomationReceiverSession) OnReport(metadata []byte, report []byte) (*types.Transaction, error) { + return _AutomationReceiver.Contract.OnReport(&_AutomationReceiver.TransactOpts, metadata, report) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) OnReport(metadata []byte, report []byte) (*types.Transaction, error) { + return _AutomationReceiver.Contract.OnReport(&_AutomationReceiver.TransactOpts, metadata, report) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "renounceOwnership") +} + +func (_AutomationReceiver *AutomationReceiverSession) RenounceOwnership() (*types.Transaction, error) { + return _AutomationReceiver.Contract.RenounceOwnership(&_AutomationReceiver.TransactOpts) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) RenounceOwnership() (*types.Transaction, error) { + return _AutomationReceiver.Contract.RenounceOwnership(&_AutomationReceiver.TransactOpts) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) SetCallAllowed(opts *bind.TransactOpts, target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setCallAllowed", target, selector, allowed) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetCallAllowed(target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetCallAllowed(&_AutomationReceiver.TransactOpts, target, selector, allowed) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetCallAllowed(target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetCallAllowed(&_AutomationReceiver.TransactOpts, target, selector, allowed) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) SetExpectedAuthor(opts *bind.TransactOpts, _author common.Address) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setExpectedAuthor", _author) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetExpectedAuthor(_author common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedAuthor(&_AutomationReceiver.TransactOpts, _author) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetExpectedAuthor(_author common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedAuthor(&_AutomationReceiver.TransactOpts, _author) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) SetExpectedWorkflowId(opts *bind.TransactOpts, _id [32]byte) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setExpectedWorkflowId", _id) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetExpectedWorkflowId(_id [32]byte) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedWorkflowId(&_AutomationReceiver.TransactOpts, _id) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetExpectedWorkflowId(_id [32]byte) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedWorkflowId(&_AutomationReceiver.TransactOpts, _id) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) SetExpectedWorkflowName(opts *bind.TransactOpts, _name string) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setExpectedWorkflowName", _name) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetExpectedWorkflowName(_name string) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedWorkflowName(&_AutomationReceiver.TransactOpts, _name) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetExpectedWorkflowName(_name string) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetExpectedWorkflowName(&_AutomationReceiver.TransactOpts, _name) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) SetForwarderAddress(opts *bind.TransactOpts, _forwarder common.Address) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setForwarderAddress", _forwarder) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetForwarderAddress(_forwarder common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetForwarderAddress(&_AutomationReceiver.TransactOpts, _forwarder) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetForwarderAddress(_forwarder common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetForwarderAddress(&_AutomationReceiver.TransactOpts, _forwarder) +} + +func (_AutomationReceiver *AutomationReceiverTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "transferOwnership", newOwner) +} + +func (_AutomationReceiver *AutomationReceiverSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.TransferOwnership(&_AutomationReceiver.TransactOpts, newOwner) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { + return _AutomationReceiver.Contract.TransferOwnership(&_AutomationReceiver.TransactOpts, newOwner) +} + +type AutomationReceiverCallAllowedSetIterator struct { + Event *AutomationReceiverCallAllowedSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverCallAllowedSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallAllowedSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallAllowedSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverCallAllowedSetIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverCallAllowedSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverCallAllowedSet struct { + Target common.Address + Selector [4]byte + Allowed bool + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterCallAllowedSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallAllowedSetIterator, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "CallAllowedSet", targetRule, selectorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverCallAllowedSetIterator{contract: _AutomationReceiver.contract, event: "CallAllowedSet", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchCallAllowedSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallAllowedSet, target []common.Address, selector [][4]byte) (event.Subscription, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "CallAllowedSet", targetRule, selectorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverCallAllowedSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallAllowedSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseCallAllowedSet(log types.Log) (*AutomationReceiverCallAllowedSet, error) { + event := new(AutomationReceiverCallAllowedSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallAllowedSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverCallExecutedIterator struct { + Event *AutomationReceiverCallExecuted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverCallExecutedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallExecuted) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallExecuted) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverCallExecutedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverCallExecutedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverCallExecuted struct { + Target common.Address + Selector [4]byte + ReturnData []byte + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterCallExecuted(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallExecutedIterator, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "CallExecuted", targetRule, selectorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverCallExecutedIterator{contract: _AutomationReceiver.contract, event: "CallExecuted", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchCallExecuted(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallExecuted, target []common.Address, selector [][4]byte) (event.Subscription, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "CallExecuted", targetRule, selectorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverCallExecuted) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallExecuted", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseCallExecuted(log types.Log) (*AutomationReceiverCallExecuted, error) { + event := new(AutomationReceiverCallExecuted) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallExecuted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverCallFailedIterator struct { + Event *AutomationReceiverCallFailed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverCallFailedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallFailed) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverCallFailed) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverCallFailedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverCallFailedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverCallFailed struct { + Target common.Address + Selector [4]byte + Reason []byte + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterCallFailed(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallFailedIterator, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "CallFailed", targetRule, selectorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverCallFailedIterator{contract: _AutomationReceiver.contract, event: "CallFailed", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchCallFailed(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallFailed, target []common.Address, selector [][4]byte) (event.Subscription, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "CallFailed", targetRule, selectorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverCallFailed) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallFailed", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseCallFailed(log types.Log) (*AutomationReceiverCallFailed, error) { + event := new(AutomationReceiverCallFailed) + if err := _AutomationReceiver.contract.UnpackLog(event, "CallFailed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverExpectedAuthorUpdatedIterator struct { + Event *AutomationReceiverExpectedAuthorUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedAuthorUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedAuthorUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverExpectedAuthorUpdated struct { + PreviousAuthor common.Address + NewAuthor common.Address + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterExpectedAuthorUpdated(opts *bind.FilterOpts, previousAuthor []common.Address, newAuthor []common.Address) (*AutomationReceiverExpectedAuthorUpdatedIterator, error) { + + var previousAuthorRule []interface{} + for _, previousAuthorItem := range previousAuthor { + previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + } + var newAuthorRule []interface{} + for _, newAuthorItem := range newAuthor { + newAuthorRule = append(newAuthorRule, newAuthorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverExpectedAuthorUpdatedIterator{contract: _AutomationReceiver.contract, event: "ExpectedAuthorUpdated", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedAuthorUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedAuthorUpdated, previousAuthor []common.Address, newAuthor []common.Address) (event.Subscription, error) { + + var previousAuthorRule []interface{} + for _, previousAuthorItem := range previousAuthor { + previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + } + var newAuthorRule []interface{} + for _, newAuthorItem := range newAuthor { + newAuthorRule = append(newAuthorRule, newAuthorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverExpectedAuthorUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseExpectedAuthorUpdated(log types.Log) (*AutomationReceiverExpectedAuthorUpdated, error) { + event := new(AutomationReceiverExpectedAuthorUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverExpectedWorkflowIdUpdatedIterator struct { + Event *AutomationReceiverExpectedWorkflowIdUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverExpectedWorkflowIdUpdated struct { + PreviousId [32]byte + NewId [32]byte + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterExpectedWorkflowIdUpdated(opts *bind.FilterOpts, previousId [][32]byte, newId [][32]byte) (*AutomationReceiverExpectedWorkflowIdUpdatedIterator, error) { + + var previousIdRule []interface{} + for _, previousIdItem := range previousId { + previousIdRule = append(previousIdRule, previousIdItem) + } + var newIdRule []interface{} + for _, newIdItem := range newId { + newIdRule = append(newIdRule, newIdItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ExpectedWorkflowIdUpdated", previousIdRule, newIdRule) + if err != nil { + return nil, err + } + return &AutomationReceiverExpectedWorkflowIdUpdatedIterator{contract: _AutomationReceiver.contract, event: "ExpectedWorkflowIdUpdated", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedWorkflowIdUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedWorkflowIdUpdated, previousId [][32]byte, newId [][32]byte) (event.Subscription, error) { + + var previousIdRule []interface{} + for _, previousIdItem := range previousId { + previousIdRule = append(previousIdRule, previousIdItem) + } + var newIdRule []interface{} + for _, newIdItem := range newId { + newIdRule = append(newIdRule, newIdItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ExpectedWorkflowIdUpdated", previousIdRule, newIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedWorkflowIdUpdated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseExpectedWorkflowIdUpdated(log types.Log) (*AutomationReceiverExpectedWorkflowIdUpdated, error) { + event := new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedWorkflowIdUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverExpectedWorkflowNameUpdatedIterator struct { + Event *AutomationReceiverExpectedWorkflowNameUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverExpectedWorkflowNameUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowNameUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowNameUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverExpectedWorkflowNameUpdatedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverExpectedWorkflowNameUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverExpectedWorkflowNameUpdated struct { + PreviousName [10]byte + NewName [10]byte + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterExpectedWorkflowNameUpdated(opts *bind.FilterOpts, previousName [][10]byte, newName [][10]byte) (*AutomationReceiverExpectedWorkflowNameUpdatedIterator, error) { + + var previousNameRule []interface{} + for _, previousNameItem := range previousName { + previousNameRule = append(previousNameRule, previousNameItem) + } + var newNameRule []interface{} + for _, newNameItem := range newName { + newNameRule = append(newNameRule, newNameItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ExpectedWorkflowNameUpdated", previousNameRule, newNameRule) + if err != nil { + return nil, err + } + return &AutomationReceiverExpectedWorkflowNameUpdatedIterator{contract: _AutomationReceiver.contract, event: "ExpectedWorkflowNameUpdated", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedWorkflowNameUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedWorkflowNameUpdated, previousName [][10]byte, newName [][10]byte) (event.Subscription, error) { + + var previousNameRule []interface{} + for _, previousNameItem := range previousName { + previousNameRule = append(previousNameRule, previousNameItem) + } + var newNameRule []interface{} + for _, newNameItem := range newName { + newNameRule = append(newNameRule, newNameItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ExpectedWorkflowNameUpdated", previousNameRule, newNameRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverExpectedWorkflowNameUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedWorkflowNameUpdated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseExpectedWorkflowNameUpdated(log types.Log) (*AutomationReceiverExpectedWorkflowNameUpdated, error) { + event := new(AutomationReceiverExpectedWorkflowNameUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedWorkflowNameUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverForwarderAddressUpdatedIterator struct { + Event *AutomationReceiverForwarderAddressUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverForwarderAddressUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverForwarderAddressUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverForwarderAddressUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverForwarderAddressUpdatedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverForwarderAddressUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverForwarderAddressUpdated struct { + PreviousForwarder common.Address + NewForwarder common.Address + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterForwarderAddressUpdated(opts *bind.FilterOpts, previousForwarder []common.Address, newForwarder []common.Address) (*AutomationReceiverForwarderAddressUpdatedIterator, error) { + + var previousForwarderRule []interface{} + for _, previousForwarderItem := range previousForwarder { + previousForwarderRule = append(previousForwarderRule, previousForwarderItem) + } + var newForwarderRule []interface{} + for _, newForwarderItem := range newForwarder { + newForwarderRule = append(newForwarderRule, newForwarderItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ForwarderAddressUpdated", previousForwarderRule, newForwarderRule) + if err != nil { + return nil, err + } + return &AutomationReceiverForwarderAddressUpdatedIterator{contract: _AutomationReceiver.contract, event: "ForwarderAddressUpdated", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchForwarderAddressUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverForwarderAddressUpdated, previousForwarder []common.Address, newForwarder []common.Address) (event.Subscription, error) { + + var previousForwarderRule []interface{} + for _, previousForwarderItem := range previousForwarder { + previousForwarderRule = append(previousForwarderRule, previousForwarderItem) + } + var newForwarderRule []interface{} + for _, newForwarderItem := range newForwarder { + newForwarderRule = append(newForwarderRule, newForwarderItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ForwarderAddressUpdated", previousForwarderRule, newForwarderRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverForwarderAddressUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ForwarderAddressUpdated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseForwarderAddressUpdated(log types.Log) (*AutomationReceiverForwarderAddressUpdated, error) { + event := new(AutomationReceiverForwarderAddressUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ForwarderAddressUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverOwnershipTransferredIterator struct { + Event *AutomationReceiverOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverOwnershipTransferred) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverOwnershipTransferred struct { + PreviousOwner common.Address + NewOwner common.Address + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*AutomationReceiverOwnershipTransferredIterator, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return &AutomationReceiverOwnershipTransferredIterator{contract: _AutomationReceiver.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *AutomationReceiverOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) { + + var previousOwnerRule []interface{} + for _, previousOwnerItem := range previousOwner { + previousOwnerRule = append(previousOwnerRule, previousOwnerItem) + } + var newOwnerRule []interface{} + for _, newOwnerItem := range newOwner { + newOwnerRule = append(newOwnerRule, newOwnerItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverOwnershipTransferred) + if err := _AutomationReceiver.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseOwnershipTransferred(log types.Log) (*AutomationReceiverOwnershipTransferred, error) { + event := new(AutomationReceiverOwnershipTransferred) + if err := _AutomationReceiver.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverSecurityWarningIterator struct { + Event *AutomationReceiverSecurityWarning + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverSecurityWarningIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverSecurityWarning) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverSecurityWarning) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverSecurityWarningIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverSecurityWarningIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverSecurityWarning struct { + Message string + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterSecurityWarning(opts *bind.FilterOpts) (*AutomationReceiverSecurityWarningIterator, error) { + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "SecurityWarning") + if err != nil { + return nil, err + } + return &AutomationReceiverSecurityWarningIterator{contract: _AutomationReceiver.contract, event: "SecurityWarning", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchSecurityWarning(opts *bind.WatchOpts, sink chan<- *AutomationReceiverSecurityWarning) (event.Subscription, error) { + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "SecurityWarning") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverSecurityWarning) + if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseSecurityWarning(log types.Log) (*AutomationReceiverSecurityWarning, error) { + event := new(AutomationReceiverSecurityWarning) + if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_AutomationReceiver *AutomationReceiver) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _AutomationReceiver.abi.Events["CallAllowedSet"].ID: + return _AutomationReceiver.ParseCallAllowedSet(log) + case _AutomationReceiver.abi.Events["CallExecuted"].ID: + return _AutomationReceiver.ParseCallExecuted(log) + case _AutomationReceiver.abi.Events["CallFailed"].ID: + return _AutomationReceiver.ParseCallFailed(log) + case _AutomationReceiver.abi.Events["ExpectedAuthorUpdated"].ID: + return _AutomationReceiver.ParseExpectedAuthorUpdated(log) + case _AutomationReceiver.abi.Events["ExpectedWorkflowIdUpdated"].ID: + return _AutomationReceiver.ParseExpectedWorkflowIdUpdated(log) + case _AutomationReceiver.abi.Events["ExpectedWorkflowNameUpdated"].ID: + return _AutomationReceiver.ParseExpectedWorkflowNameUpdated(log) + case _AutomationReceiver.abi.Events["ForwarderAddressUpdated"].ID: + return _AutomationReceiver.ParseForwarderAddressUpdated(log) + case _AutomationReceiver.abi.Events["OwnershipTransferred"].ID: + return _AutomationReceiver.ParseOwnershipTransferred(log) + case _AutomationReceiver.abi.Events["SecurityWarning"].ID: + return _AutomationReceiver.ParseSecurityWarning(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (AutomationReceiverCallAllowedSet) Topic() common.Hash { + return common.HexToHash("0x0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7") +} + +func (AutomationReceiverCallExecuted) Topic() common.Hash { + return common.HexToHash("0xbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb884") +} + +func (AutomationReceiverCallFailed) Topic() common.Hash { + return common.HexToHash("0xefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b6") +} + +func (AutomationReceiverExpectedAuthorUpdated) Topic() common.Hash { + return common.HexToHash("0x3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31") +} + +func (AutomationReceiverExpectedWorkflowIdUpdated) Topic() common.Hash { + return common.HexToHash("0x0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03") +} + +func (AutomationReceiverExpectedWorkflowNameUpdated) Topic() common.Hash { + return common.HexToHash("0x1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5") +} + +func (AutomationReceiverForwarderAddressUpdated) Topic() common.Hash { + return common.HexToHash("0x039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e") +} + +func (AutomationReceiverOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (AutomationReceiverSecurityWarning) Topic() common.Hash { + return common.HexToHash("0x704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7") +} + +func (_AutomationReceiver *AutomationReceiver) Address() common.Address { + return _AutomationReceiver.address +} + +type AutomationReceiverInterface interface { + GetExpectedAuthor(opts *bind.CallOpts) (common.Address, error) + + GetExpectedWorkflowId(opts *bind.CallOpts) ([32]byte, error) + + GetExpectedWorkflowName(opts *bind.CallOpts) ([10]byte, error) + + GetForwarderAddress(opts *bind.CallOpts) (common.Address, error) + + IsCallAllowed(opts *bind.CallOpts, target common.Address, selector [4]byte) (bool, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) + + RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + SetCallAllowed(opts *bind.TransactOpts, target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) + + SetExpectedAuthor(opts *bind.TransactOpts, _author common.Address) (*types.Transaction, error) + + SetExpectedWorkflowId(opts *bind.TransactOpts, _id [32]byte) (*types.Transaction, error) + + SetExpectedWorkflowName(opts *bind.TransactOpts, _name string) (*types.Transaction, error) + + SetForwarderAddress(opts *bind.TransactOpts, _forwarder common.Address) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) + + FilterCallAllowedSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallAllowedSetIterator, error) + + WatchCallAllowedSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallAllowedSet, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseCallAllowedSet(log types.Log) (*AutomationReceiverCallAllowedSet, error) + + FilterCallExecuted(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallExecutedIterator, error) + + WatchCallExecuted(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallExecuted, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseCallExecuted(log types.Log) (*AutomationReceiverCallExecuted, error) + + FilterCallFailed(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallFailedIterator, error) + + WatchCallFailed(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallFailed, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseCallFailed(log types.Log) (*AutomationReceiverCallFailed, error) + + FilterExpectedAuthorUpdated(opts *bind.FilterOpts, previousAuthor []common.Address, newAuthor []common.Address) (*AutomationReceiverExpectedAuthorUpdatedIterator, error) + + WatchExpectedAuthorUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedAuthorUpdated, previousAuthor []common.Address, newAuthor []common.Address) (event.Subscription, error) + + ParseExpectedAuthorUpdated(log types.Log) (*AutomationReceiverExpectedAuthorUpdated, error) + + FilterExpectedWorkflowIdUpdated(opts *bind.FilterOpts, previousId [][32]byte, newId [][32]byte) (*AutomationReceiverExpectedWorkflowIdUpdatedIterator, error) + + WatchExpectedWorkflowIdUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedWorkflowIdUpdated, previousId [][32]byte, newId [][32]byte) (event.Subscription, error) + + ParseExpectedWorkflowIdUpdated(log types.Log) (*AutomationReceiverExpectedWorkflowIdUpdated, error) + + FilterExpectedWorkflowNameUpdated(opts *bind.FilterOpts, previousName [][10]byte, newName [][10]byte) (*AutomationReceiverExpectedWorkflowNameUpdatedIterator, error) + + WatchExpectedWorkflowNameUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedWorkflowNameUpdated, previousName [][10]byte, newName [][10]byte) (event.Subscription, error) + + ParseExpectedWorkflowNameUpdated(log types.Log) (*AutomationReceiverExpectedWorkflowNameUpdated, error) + + FilterForwarderAddressUpdated(opts *bind.FilterOpts, previousForwarder []common.Address, newForwarder []common.Address) (*AutomationReceiverForwarderAddressUpdatedIterator, error) + + WatchForwarderAddressUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverForwarderAddressUpdated, previousForwarder []common.Address, newForwarder []common.Address) (event.Subscription, error) + + ParseForwarderAddressUpdated(log types.Log) (*AutomationReceiverForwarderAddressUpdated, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*AutomationReceiverOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *AutomationReceiverOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*AutomationReceiverOwnershipTransferred, error) + + FilterSecurityWarning(opts *bind.FilterOpts) (*AutomationReceiverSecurityWarningIterator, error) + + WatchSecurityWarning(opts *bind.WatchOpts, sink chan<- *AutomationReceiverSecurityWarning) (event.Subscription, error) + + ParseSecurityWarning(log types.Log) (*AutomationReceiverSecurityWarning, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 0ac64d06bc..6cc98077c2 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,6 +3,7 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 +automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin 73808cf06a4320a9da36308fdeb8640077c633cbc7515d6dc05c55d9469046be automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef diff --git a/gethwrappers/go_generate_automation.go b/gethwrappers/go_generate_automation.go index 4b87b5fb52..006f736c49 100644 --- a/gethwrappers/go_generate_automation.go +++ b/gethwrappers/go_generate_automation.go @@ -24,6 +24,7 @@ package gethwrappers //go:generate go run ./generation/wrap.go automation IChainModule i_chain_module //go:generate go run ./generation/wrap.go automation IAutomationV21PlusCommon i_automation_v21_plus_common //go:generate go run ./generation/wrap.go automation MockETHUSDAggregator mock_ethusd_aggregator_wrapper +//go:generate go run ./generation/generate_automation/wrap.go AutomationReceiver AutomationReceiver automation_receiver //go:generate go run ./generation/wrap.go automation ILogAutomation i_log_automation //go:generate go run ./generation/wrap.go automation AutomationForwarderLogic automation_forwarder_logic From 526e1a53b8308173cd8a80911831dccc04c8bab5 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 14:36:24 -0300 Subject: [PATCH 02/29] Enhance AutomationReceiver with low-level call safety check - Added a comment to disable the solhint rule for low-level calls in AutomationReceiver.sol to clarify intent and improve code safety. --- contracts/src/v0.8/automation/AutomationReceiver.sol | 1 + 1 file changed, 1 insertion(+) diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 615531d854..5bda2f2179 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -58,6 +58,7 @@ contract AutomationReceiver is ReceiverTemplate { } if (!s_callAllowed[target][selector]) revert CallNotAllowed(target, selector); + // solhint-disable-next-line avoid-low-level-calls (bool success, bytes memory returnData) = target.call(data); if (success) { emit CallExecuted(target, selector, returnData); From 41c3339da91278347e652edd5bdf0c80e1a0592d Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:04:00 -0300 Subject: [PATCH 03/29] Update dependencies in go.mod and go.sum - Bump go-ethereum from v1.17.0 to v1.17.3 - Update go-eth-kzg from v1.4.0 to v1.5.0 - Upgrade opentelemetry packages from v1.39.0 to v1.40.0 - Adjust blst version to v0.3.16 --- gethwrappers/go.mod | 14 +++++++------- gethwrappers/go.sum | 32 ++++++++++++++++---------------- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/gethwrappers/go.mod b/gethwrappers/go.mod index e4d5c9f1d5..e1662fc14f 100644 --- a/gethwrappers/go.mod +++ b/gethwrappers/go.mod @@ -3,7 +3,7 @@ module github.com/smartcontractkit/chainlink-evm/gethwrappers go 1.24.5 require ( - github.com/ethereum/go-ethereum v1.17.0 + github.com/ethereum/go-ethereum v1.17.3 github.com/fatih/color v1.18.0 github.com/pkg/errors v0.9.1 github.com/smartcontractkit/chainlink-evm/gethwrappers/helpers v0.0.0-20260113095857-e13e0dd04d9f @@ -34,13 +34,13 @@ require ( github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/gnark-crypto v0.18.1 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect - github.com/crate-crypto/go-eth-kzg v1.4.0 // indirect + github.com/crate-crypto/go-eth-kzg v1.5.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/dchest/siphash v1.2.3 // indirect github.com/deckarep/golang-set/v2 v2.6.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/emicklei/dot v1.6.2 // indirect - github.com/ethereum/c-kzg-4844/v2 v2.1.5 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.6 // indirect github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab // indirect github.com/ferranbt/fastssz v0.1.4 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect @@ -88,7 +88,7 @@ require ( github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/stephenlacy/go-ethereum-hdwallet v0.0.0-20230913225845-a4fa94429863 // indirect - github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe // indirect + github.com/supranational/blst v0.3.16 // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect @@ -96,9 +96,9 @@ require ( github.com/urfave/cli/v2 v2.27.5 // indirect github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.39.0 // indirect - go.opentelemetry.io/otel/metric v1.39.0 // indirect - go.opentelemetry.io/otel/trace v1.39.0 // indirect + go.opentelemetry.io/otel v1.40.0 // indirect + go.opentelemetry.io/otel/metric v1.40.0 // indirect + go.opentelemetry.io/otel/trace v1.40.0 // indirect golang.org/x/crypto v0.48.0 // indirect golang.org/x/exp v0.0.0-20240213143201-ec583247a57a // indirect golang.org/x/sync v0.19.0 // indirect diff --git a/gethwrappers/go.sum b/gethwrappers/go.sum index ff3b0f5918..b09405c779 100644 --- a/gethwrappers/go.sum +++ b/gethwrappers/go.sum @@ -63,8 +63,8 @@ github.com/consensys/gnark-crypto v0.18.1 h1:RyLV6UhPRoYYzaFnPQA4qK3DyuDgkTgskDd github.com/consensys/gnark-crypto v0.18.1/go.mod h1:L3mXGFTe1ZN+RSJ+CLjUt9x7PNdx8ubaYfDROyp2Z8c= github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/crate-crypto/go-eth-kzg v1.4.0 h1:WzDGjHk4gFg6YzV0rJOAsTK4z3Qkz5jd4RE3DAvPFkg= -github.com/crate-crypto/go-eth-kzg v1.4.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= +github.com/crate-crypto/go-eth-kzg v1.5.0 h1:FYRiJMJG2iv+2Dy3fi14SVGjcPteZ5HAAUe4YWlJygc= +github.com/crate-crypto/go-eth-kzg v1.5.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -85,12 +85,12 @@ github.com/deepmap/oapi-codegen v1.6.0 h1:w/d1ntwh91XI0b/8ja7+u5SvA4IFfM0UNNLmiD github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5 h1:aVtoLK5xwJ6c5RiqO8g8ptJ5KU+2Hdquf6G3aXiHh5s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5/go.mod h1:u59hRTTah4Co6i9fDWtiCjTrblJv0UwsqZKCc0GfgUs= +github.com/ethereum/c-kzg-4844/v2 v2.1.6 h1:xQymkKCT5E2Jiaoqf3v4wsNgjZLY0lRSkZn27fRjSls= +github.com/ethereum/c-kzg-4844/v2 v2.1.6/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= -github.com/ethereum/go-ethereum v1.17.0 h1:2D+1Fe23CwZ5tQoAS5DfwKFNI1HGcTwi65/kRlAVxes= -github.com/ethereum/go-ethereum v1.17.0/go.mod h1:2W3msvdosS/MCWytpqTcqgFiRYbTH59FxDJzqah120o= +github.com/ethereum/go-ethereum v1.17.3 h1:Ev/sQHH+UdKZHWjuVzhu2pxhi/sXaPZl23Q+Q5LDd4Q= +github.com/ethereum/go-ethereum v1.17.3/go.mod h1:f2EhRwqewIZkGoQekywI2Y2RZAMTSavLNkD9qItFy1A= github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM= github.com/fatih/color v1.18.0/go.mod h1:4FelSpRwEGDpQ12mAdzqdOukCy4u8WUtOY6lkT/6HfU= github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= @@ -272,8 +272,8 @@ github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXl github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe h1:nbdqkIGOGfUAD54q1s2YBcBz/WcsxCO9HUQ4aGV5hUw= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.16 h1:bTDadT+3fK497EvLdWRQEjiGnUtzJ7jjIUMF0jqwYhE= +github.com/supranational/blst v0.3.16/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= @@ -293,14 +293,14 @@ github.com/zksync-sdk/zksync2-go v1.1.0 h1:cRA1GlNrBEwLqvBLq5Xu22YCpbBeUBb4LKx5W github.com/zksync-sdk/zksync2-go v1.1.0/go.mod h1:NWNlQS21isOsSsn+hLRAPpiuv+3P+LcdaZNuRt2T5Yo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= -go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= -go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= -go.opentelemetry.io/otel/metric v1.39.0/go.mod h1:jrZSWL33sD7bBxg1xjrqyDjnuzTUB0x1nBERXd7Ftcs= -go.opentelemetry.io/otel/sdk v1.39.0 h1:nMLYcjVsvdui1B/4FRkwjzoRVsMK8uL/cj0OyhKzt18= -go.opentelemetry.io/otel/sdk v1.39.0/go.mod h1:vDojkC4/jsTJsE+kh+LXYQlbL8CgrEcwmt1ENZszdJE= -go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= -go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= +go.opentelemetry.io/otel v1.40.0 h1:oA5YeOcpRTXq6NN7frwmwFR0Cn3RhTVZvXsP4duvCms= +go.opentelemetry.io/otel v1.40.0/go.mod h1:IMb+uXZUKkMXdPddhwAHm6UfOwJyh4ct1ybIlV14J0g= +go.opentelemetry.io/otel/metric v1.40.0 h1:rcZe317KPftE2rstWIBitCdVp89A2HqjkxR3c11+p9g= +go.opentelemetry.io/otel/metric v1.40.0/go.mod h1:ib/crwQH7N3r5kfiBZQbwrTge743UDc7DTFVZrrXnqc= +go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= +go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= +go.opentelemetry.io/otel/trace v1.40.0 h1:WA4etStDttCSYuhwvEa8OP8I5EWu24lkOzp+ZYblVjw= +go.opentelemetry.io/otel/trace v1.40.0/go.mod h1:zeAhriXecNGP/s2SEG3+Y8X9ujcJOTqQ5RgdEJcawiA= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= From b0f0cd5e04725ae1831fbcf6712df4e03797e11f Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:09:43 -0300 Subject: [PATCH 04/29] Revert "Update dependencies in go.mod and go.sum" This reverts commit 41c3339da91278347e652edd5bdf0c80e1a0592d. --- gethwrappers/go.mod | 14 +++++++------- gethwrappers/go.sum | 32 ++++++++++++++++---------------- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/gethwrappers/go.mod b/gethwrappers/go.mod index e1662fc14f..e4d5c9f1d5 100644 --- a/gethwrappers/go.mod +++ b/gethwrappers/go.mod @@ -3,7 +3,7 @@ module github.com/smartcontractkit/chainlink-evm/gethwrappers go 1.24.5 require ( - github.com/ethereum/go-ethereum v1.17.3 + github.com/ethereum/go-ethereum v1.17.0 github.com/fatih/color v1.18.0 github.com/pkg/errors v0.9.1 github.com/smartcontractkit/chainlink-evm/gethwrappers/helpers v0.0.0-20260113095857-e13e0dd04d9f @@ -34,13 +34,13 @@ require ( github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/gnark-crypto v0.18.1 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect - github.com/crate-crypto/go-eth-kzg v1.5.0 // indirect + github.com/crate-crypto/go-eth-kzg v1.4.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/dchest/siphash v1.2.3 // indirect github.com/deckarep/golang-set/v2 v2.6.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/emicklei/dot v1.6.2 // indirect - github.com/ethereum/c-kzg-4844/v2 v2.1.6 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.5 // indirect github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab // indirect github.com/ferranbt/fastssz v0.1.4 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect @@ -88,7 +88,7 @@ require ( github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/stephenlacy/go-ethereum-hdwallet v0.0.0-20230913225845-a4fa94429863 // indirect - github.com/supranational/blst v0.3.16 // indirect + github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect @@ -96,9 +96,9 @@ require ( github.com/urfave/cli/v2 v2.27.5 // indirect github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.40.0 // indirect - go.opentelemetry.io/otel/metric v1.40.0 // indirect - go.opentelemetry.io/otel/trace v1.40.0 // indirect + go.opentelemetry.io/otel v1.39.0 // indirect + go.opentelemetry.io/otel/metric v1.39.0 // indirect + go.opentelemetry.io/otel/trace v1.39.0 // indirect golang.org/x/crypto v0.48.0 // indirect golang.org/x/exp v0.0.0-20240213143201-ec583247a57a // indirect golang.org/x/sync v0.19.0 // indirect diff --git a/gethwrappers/go.sum b/gethwrappers/go.sum index b09405c779..ff3b0f5918 100644 --- a/gethwrappers/go.sum +++ b/gethwrappers/go.sum @@ -63,8 +63,8 @@ github.com/consensys/gnark-crypto v0.18.1 h1:RyLV6UhPRoYYzaFnPQA4qK3DyuDgkTgskDd github.com/consensys/gnark-crypto v0.18.1/go.mod h1:L3mXGFTe1ZN+RSJ+CLjUt9x7PNdx8ubaYfDROyp2Z8c= github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/crate-crypto/go-eth-kzg v1.5.0 h1:FYRiJMJG2iv+2Dy3fi14SVGjcPteZ5HAAUe4YWlJygc= -github.com/crate-crypto/go-eth-kzg v1.5.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= +github.com/crate-crypto/go-eth-kzg v1.4.0 h1:WzDGjHk4gFg6YzV0rJOAsTK4z3Qkz5jd4RE3DAvPFkg= +github.com/crate-crypto/go-eth-kzg v1.4.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -85,12 +85,12 @@ github.com/deepmap/oapi-codegen v1.6.0 h1:w/d1ntwh91XI0b/8ja7+u5SvA4IFfM0UNNLmiD github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/ethereum/c-kzg-4844/v2 v2.1.6 h1:xQymkKCT5E2Jiaoqf3v4wsNgjZLY0lRSkZn27fRjSls= -github.com/ethereum/c-kzg-4844/v2 v2.1.6/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= +github.com/ethereum/c-kzg-4844/v2 v2.1.5 h1:aVtoLK5xwJ6c5RiqO8g8ptJ5KU+2Hdquf6G3aXiHh5s= +github.com/ethereum/c-kzg-4844/v2 v2.1.5/go.mod h1:u59hRTTah4Co6i9fDWtiCjTrblJv0UwsqZKCc0GfgUs= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= -github.com/ethereum/go-ethereum v1.17.3 h1:Ev/sQHH+UdKZHWjuVzhu2pxhi/sXaPZl23Q+Q5LDd4Q= -github.com/ethereum/go-ethereum v1.17.3/go.mod h1:f2EhRwqewIZkGoQekywI2Y2RZAMTSavLNkD9qItFy1A= +github.com/ethereum/go-ethereum v1.17.0 h1:2D+1Fe23CwZ5tQoAS5DfwKFNI1HGcTwi65/kRlAVxes= +github.com/ethereum/go-ethereum v1.17.0/go.mod h1:2W3msvdosS/MCWytpqTcqgFiRYbTH59FxDJzqah120o= github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM= github.com/fatih/color v1.18.0/go.mod h1:4FelSpRwEGDpQ12mAdzqdOukCy4u8WUtOY6lkT/6HfU= github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= @@ -272,8 +272,8 @@ github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXl github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= -github.com/supranational/blst v0.3.16 h1:bTDadT+3fK497EvLdWRQEjiGnUtzJ7jjIUMF0jqwYhE= -github.com/supranational/blst v0.3.16/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe h1:nbdqkIGOGfUAD54q1s2YBcBz/WcsxCO9HUQ4aGV5hUw= +github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= @@ -293,14 +293,14 @@ github.com/zksync-sdk/zksync2-go v1.1.0 h1:cRA1GlNrBEwLqvBLq5Xu22YCpbBeUBb4LKx5W github.com/zksync-sdk/zksync2-go v1.1.0/go.mod h1:NWNlQS21isOsSsn+hLRAPpiuv+3P+LcdaZNuRt2T5Yo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/otel v1.40.0 h1:oA5YeOcpRTXq6NN7frwmwFR0Cn3RhTVZvXsP4duvCms= -go.opentelemetry.io/otel v1.40.0/go.mod h1:IMb+uXZUKkMXdPddhwAHm6UfOwJyh4ct1ybIlV14J0g= -go.opentelemetry.io/otel/metric v1.40.0 h1:rcZe317KPftE2rstWIBitCdVp89A2HqjkxR3c11+p9g= -go.opentelemetry.io/otel/metric v1.40.0/go.mod h1:ib/crwQH7N3r5kfiBZQbwrTge743UDc7DTFVZrrXnqc= -go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= -go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= -go.opentelemetry.io/otel/trace v1.40.0 h1:WA4etStDttCSYuhwvEa8OP8I5EWu24lkOzp+ZYblVjw= -go.opentelemetry.io/otel/trace v1.40.0/go.mod h1:zeAhriXecNGP/s2SEG3+Y8X9ujcJOTqQ5RgdEJcawiA= +go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= +go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= +go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= +go.opentelemetry.io/otel/metric v1.39.0/go.mod h1:jrZSWL33sD7bBxg1xjrqyDjnuzTUB0x1nBERXd7Ftcs= +go.opentelemetry.io/otel/sdk v1.39.0 h1:nMLYcjVsvdui1B/4FRkwjzoRVsMK8uL/cj0OyhKzt18= +go.opentelemetry.io/otel/sdk v1.39.0/go.mod h1:vDojkC4/jsTJsE+kh+LXYQlbL8CgrEcwmt1ENZszdJE= +go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= +go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= From 1e51febe076b036413d590dca5e62c09928f7da3 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:25:11 -0300 Subject: [PATCH 05/29] Refactor constructor and function signatures in AutomationReceiver and ReceiverTemplate for improved readability - Updated constructor and function signatures to use multi-line formatting for better clarity. - No functional changes were made, only formatting adjustments to enhance code maintainability. --- .../v0.8/automation/AutomationReceiver.sol | 8 +++-- .../src/v0.8/automation/ReceiverTemplate.sol | 32 ++++++++++++++----- 2 files changed, 30 insertions(+), 10 deletions(-) diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 5bda2f2179..49b8fc6680 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -30,7 +30,9 @@ contract AutomationReceiver is ReceiverTemplate { error MissingSelector(); error CallNotAllowed(address target, bytes4 selector); - constructor(address _forwarder) ReceiverTemplate(_forwarder) {} + constructor( + address _forwarder + ) ReceiverTemplate(_forwarder) {} /// @notice Allow or disallow the receiver to call `selector` on `target`. Owner-only. function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { @@ -46,7 +48,9 @@ contract AutomationReceiver is ReceiverTemplate { /// @notice Decodes and executes the call encoded in the CRE report. /// @param report ABI-encoded (address target, bytes data). - function _processReport(bytes calldata report) internal override { + function _processReport( + bytes calldata report + ) internal override { (address target, bytes memory data) = abi.decode(report, (address, bytes)); if (target == address(0)) revert InvalidTargetAddress(); diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index 908ed51dd9..1e8ab75e66 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -31,7 +31,9 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { event ExpectedWorkflowIdUpdated(bytes32 indexed previousId, bytes32 indexed newId); event SecurityWarning(string message); - constructor(address _forwarderAddress) Ownable() { + constructor( + address _forwarderAddress + ) Ownable() { if (_forwarderAddress == address(0)) revert InvalidForwarderAddress(); s_forwarderAddress = _forwarderAddress; emit ForwarderAddressUpdated(address(0), _forwarderAddress); @@ -77,20 +79,26 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { _processReport(report); } - function setForwarderAddress(address _forwarder) external onlyOwner { + function setForwarderAddress( + address _forwarder + ) external onlyOwner { address previousForwarder = s_forwarderAddress; if (_forwarder == address(0)) emit SecurityWarning("Forwarder address set to zero - contract is now INSECURE"); s_forwarderAddress = _forwarder; emit ForwarderAddressUpdated(previousForwarder, _forwarder); } - function setExpectedAuthor(address _author) external onlyOwner { + function setExpectedAuthor( + address _author + ) external onlyOwner { address previousAuthor = s_expectedAuthor; s_expectedAuthor = _author; emit ExpectedAuthorUpdated(previousAuthor, _author); } - function setExpectedWorkflowName(string calldata _name) external onlyOwner { + function setExpectedWorkflowName( + string calldata _name + ) external onlyOwner { bytes10 previousName = s_expectedWorkflowName; if (bytes(_name).length == 0) { s_expectedWorkflowName = bytes10(0); @@ -107,13 +115,17 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { emit ExpectedWorkflowNameUpdated(previousName, s_expectedWorkflowName); } - function setExpectedWorkflowId(bytes32 _id) external onlyOwner { + function setExpectedWorkflowId( + bytes32 _id + ) external onlyOwner { bytes32 previousId = s_expectedWorkflowId; s_expectedWorkflowId = _id; emit ExpectedWorkflowIdUpdated(previousId, _id); } - function _bytesToHexString(bytes memory data) private pure returns (bytes memory) { + function _bytesToHexString( + bytes memory data + ) private pure returns (bytes memory) { bytes memory hexString = new bytes(data.length * 2); for (uint256 i = 0; i < data.length; i++) { hexString[i * 2] = HEX_CHARS[uint8(data[i] >> 4)]; @@ -133,10 +145,14 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { return (workflowId, workflowName, workflowOwner); } - function _processReport(bytes calldata report) internal virtual; + function _processReport( + bytes calldata report + ) internal virtual; /// @inheritdoc IERC165 - function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { + function supportsInterface( + bytes4 interfaceId + ) public view virtual override returns (bool) { return interfaceId == type(IReceiver).interfaceId || interfaceId == type(IERC165).interfaceId; } } From f42c6af50b1f1ef954f42acd9236b75921ffa3ae Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:40:15 -0300 Subject: [PATCH 06/29] Update dependencies in go.mod and go.sum - Bump go-ethereum from v1.17.0 to v1.17.3 - Update go-eth-kzg from v1.4.0 to v1.5.0 - Upgrade opentelemetry packages from v1.39.0 to v1.40.0 - Adjust blst version to v0.3.16 --- gethwrappers/go.mod | 14 +++++++------- gethwrappers/go.sum | 32 ++++++++++++++++---------------- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/gethwrappers/go.mod b/gethwrappers/go.mod index e4d5c9f1d5..e1662fc14f 100644 --- a/gethwrappers/go.mod +++ b/gethwrappers/go.mod @@ -3,7 +3,7 @@ module github.com/smartcontractkit/chainlink-evm/gethwrappers go 1.24.5 require ( - github.com/ethereum/go-ethereum v1.17.0 + github.com/ethereum/go-ethereum v1.17.3 github.com/fatih/color v1.18.0 github.com/pkg/errors v0.9.1 github.com/smartcontractkit/chainlink-evm/gethwrappers/helpers v0.0.0-20260113095857-e13e0dd04d9f @@ -34,13 +34,13 @@ require ( github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/gnark-crypto v0.18.1 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect - github.com/crate-crypto/go-eth-kzg v1.4.0 // indirect + github.com/crate-crypto/go-eth-kzg v1.5.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/dchest/siphash v1.2.3 // indirect github.com/deckarep/golang-set/v2 v2.6.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/emicklei/dot v1.6.2 // indirect - github.com/ethereum/c-kzg-4844/v2 v2.1.5 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.6 // indirect github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab // indirect github.com/ferranbt/fastssz v0.1.4 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect @@ -88,7 +88,7 @@ require ( github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/stephenlacy/go-ethereum-hdwallet v0.0.0-20230913225845-a4fa94429863 // indirect - github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe // indirect + github.com/supranational/blst v0.3.16 // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect @@ -96,9 +96,9 @@ require ( github.com/urfave/cli/v2 v2.27.5 // indirect github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.39.0 // indirect - go.opentelemetry.io/otel/metric v1.39.0 // indirect - go.opentelemetry.io/otel/trace v1.39.0 // indirect + go.opentelemetry.io/otel v1.40.0 // indirect + go.opentelemetry.io/otel/metric v1.40.0 // indirect + go.opentelemetry.io/otel/trace v1.40.0 // indirect golang.org/x/crypto v0.48.0 // indirect golang.org/x/exp v0.0.0-20240213143201-ec583247a57a // indirect golang.org/x/sync v0.19.0 // indirect diff --git a/gethwrappers/go.sum b/gethwrappers/go.sum index ff3b0f5918..b09405c779 100644 --- a/gethwrappers/go.sum +++ b/gethwrappers/go.sum @@ -63,8 +63,8 @@ github.com/consensys/gnark-crypto v0.18.1 h1:RyLV6UhPRoYYzaFnPQA4qK3DyuDgkTgskDd github.com/consensys/gnark-crypto v0.18.1/go.mod h1:L3mXGFTe1ZN+RSJ+CLjUt9x7PNdx8ubaYfDROyp2Z8c= github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/crate-crypto/go-eth-kzg v1.4.0 h1:WzDGjHk4gFg6YzV0rJOAsTK4z3Qkz5jd4RE3DAvPFkg= -github.com/crate-crypto/go-eth-kzg v1.4.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= +github.com/crate-crypto/go-eth-kzg v1.5.0 h1:FYRiJMJG2iv+2Dy3fi14SVGjcPteZ5HAAUe4YWlJygc= +github.com/crate-crypto/go-eth-kzg v1.5.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -85,12 +85,12 @@ github.com/deepmap/oapi-codegen v1.6.0 h1:w/d1ntwh91XI0b/8ja7+u5SvA4IFfM0UNNLmiD github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5 h1:aVtoLK5xwJ6c5RiqO8g8ptJ5KU+2Hdquf6G3aXiHh5s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5/go.mod h1:u59hRTTah4Co6i9fDWtiCjTrblJv0UwsqZKCc0GfgUs= +github.com/ethereum/c-kzg-4844/v2 v2.1.6 h1:xQymkKCT5E2Jiaoqf3v4wsNgjZLY0lRSkZn27fRjSls= +github.com/ethereum/c-kzg-4844/v2 v2.1.6/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= -github.com/ethereum/go-ethereum v1.17.0 h1:2D+1Fe23CwZ5tQoAS5DfwKFNI1HGcTwi65/kRlAVxes= -github.com/ethereum/go-ethereum v1.17.0/go.mod h1:2W3msvdosS/MCWytpqTcqgFiRYbTH59FxDJzqah120o= +github.com/ethereum/go-ethereum v1.17.3 h1:Ev/sQHH+UdKZHWjuVzhu2pxhi/sXaPZl23Q+Q5LDd4Q= +github.com/ethereum/go-ethereum v1.17.3/go.mod h1:f2EhRwqewIZkGoQekywI2Y2RZAMTSavLNkD9qItFy1A= github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM= github.com/fatih/color v1.18.0/go.mod h1:4FelSpRwEGDpQ12mAdzqdOukCy4u8WUtOY6lkT/6HfU= github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= @@ -272,8 +272,8 @@ github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXl github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe h1:nbdqkIGOGfUAD54q1s2YBcBz/WcsxCO9HUQ4aGV5hUw= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.16 h1:bTDadT+3fK497EvLdWRQEjiGnUtzJ7jjIUMF0jqwYhE= +github.com/supranational/blst v0.3.16/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= @@ -293,14 +293,14 @@ github.com/zksync-sdk/zksync2-go v1.1.0 h1:cRA1GlNrBEwLqvBLq5Xu22YCpbBeUBb4LKx5W github.com/zksync-sdk/zksync2-go v1.1.0/go.mod h1:NWNlQS21isOsSsn+hLRAPpiuv+3P+LcdaZNuRt2T5Yo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= -go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= -go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= -go.opentelemetry.io/otel/metric v1.39.0/go.mod h1:jrZSWL33sD7bBxg1xjrqyDjnuzTUB0x1nBERXd7Ftcs= -go.opentelemetry.io/otel/sdk v1.39.0 h1:nMLYcjVsvdui1B/4FRkwjzoRVsMK8uL/cj0OyhKzt18= -go.opentelemetry.io/otel/sdk v1.39.0/go.mod h1:vDojkC4/jsTJsE+kh+LXYQlbL8CgrEcwmt1ENZszdJE= -go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= -go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= +go.opentelemetry.io/otel v1.40.0 h1:oA5YeOcpRTXq6NN7frwmwFR0Cn3RhTVZvXsP4duvCms= +go.opentelemetry.io/otel v1.40.0/go.mod h1:IMb+uXZUKkMXdPddhwAHm6UfOwJyh4ct1ybIlV14J0g= +go.opentelemetry.io/otel/metric v1.40.0 h1:rcZe317KPftE2rstWIBitCdVp89A2HqjkxR3c11+p9g= +go.opentelemetry.io/otel/metric v1.40.0/go.mod h1:ib/crwQH7N3r5kfiBZQbwrTge743UDc7DTFVZrrXnqc= +go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= +go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= +go.opentelemetry.io/otel/trace v1.40.0 h1:WA4etStDttCSYuhwvEa8OP8I5EWu24lkOzp+ZYblVjw= +go.opentelemetry.io/otel/trace v1.40.0/go.mod h1:zeAhriXecNGP/s2SEG3+Y8X9ujcJOTqQ5RgdEJcawiA= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= From 7701584aa39e94d7ddbaa5b543784d9e11661cef Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:44:35 -0300 Subject: [PATCH 07/29] Bump go.opentelemetry.io/otel to v1.44.0 to fix CVE --- gethwrappers/go.mod | 8 ++++---- gethwrappers/go.sum | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/gethwrappers/go.mod b/gethwrappers/go.mod index e1662fc14f..776f5ba8d2 100644 --- a/gethwrappers/go.mod +++ b/gethwrappers/go.mod @@ -1,6 +1,6 @@ module github.com/smartcontractkit/chainlink-evm/gethwrappers -go 1.24.5 +go 1.25.0 require ( github.com/ethereum/go-ethereum v1.17.3 @@ -96,9 +96,9 @@ require ( github.com/urfave/cli/v2 v2.27.5 // indirect github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.40.0 // indirect - go.opentelemetry.io/otel/metric v1.40.0 // indirect - go.opentelemetry.io/otel/trace v1.40.0 // indirect + go.opentelemetry.io/otel v1.44.0 // indirect + go.opentelemetry.io/otel/metric v1.44.0 // indirect + go.opentelemetry.io/otel/trace v1.44.0 // indirect golang.org/x/crypto v0.48.0 // indirect golang.org/x/exp v0.0.0-20240213143201-ec583247a57a // indirect golang.org/x/sync v0.19.0 // indirect diff --git a/gethwrappers/go.sum b/gethwrappers/go.sum index b09405c779..aa521cb4e2 100644 --- a/gethwrappers/go.sum +++ b/gethwrappers/go.sum @@ -293,14 +293,14 @@ github.com/zksync-sdk/zksync2-go v1.1.0 h1:cRA1GlNrBEwLqvBLq5Xu22YCpbBeUBb4LKx5W github.com/zksync-sdk/zksync2-go v1.1.0/go.mod h1:NWNlQS21isOsSsn+hLRAPpiuv+3P+LcdaZNuRt2T5Yo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/otel v1.40.0 h1:oA5YeOcpRTXq6NN7frwmwFR0Cn3RhTVZvXsP4duvCms= -go.opentelemetry.io/otel v1.40.0/go.mod h1:IMb+uXZUKkMXdPddhwAHm6UfOwJyh4ct1ybIlV14J0g= -go.opentelemetry.io/otel/metric v1.40.0 h1:rcZe317KPftE2rstWIBitCdVp89A2HqjkxR3c11+p9g= -go.opentelemetry.io/otel/metric v1.40.0/go.mod h1:ib/crwQH7N3r5kfiBZQbwrTge743UDc7DTFVZrrXnqc= +go.opentelemetry.io/otel v1.44.0 h1:JjwHmHpA4iZ3wBxluu2fbbE7j4kqlE8jXyAyPXH7HqU= +go.opentelemetry.io/otel v1.44.0/go.mod h1:BMgjTHL9WPRlRjL2oZCBTL4whCGtXch2H4BhOPIAyYc= +go.opentelemetry.io/otel/metric v1.44.0 h1:1w0gILTcHdr3YI+ixLyjemwrVnsMURbTZFrSYCdDdmc= +go.opentelemetry.io/otel/metric v1.44.0/go.mod h1:8O7hanEPBNgEMmybD3s2VBKcgWOCsA6tzHBPODAiquo= go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= -go.opentelemetry.io/otel/trace v1.40.0 h1:WA4etStDttCSYuhwvEa8OP8I5EWu24lkOzp+ZYblVjw= -go.opentelemetry.io/otel/trace v1.40.0/go.mod h1:zeAhriXecNGP/s2SEG3+Y8X9ujcJOTqQ5RgdEJcawiA= +go.opentelemetry.io/otel/trace v1.44.0 h1:jxF5CsGYCe74MCRx2X4g7WsY/VBKRqqpNvXlX/6gtIk= +go.opentelemetry.io/otel/trace v1.44.0/go.mod h1:oLl1jrMQAVo6v3GAggN+1VH9VIz9iUSvW53sW1Q8PIE= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= From e15bde7761f1e303268f8bf09d6b076567837a8e Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 15:57:45 -0300 Subject: [PATCH 08/29] Update go.mod and go.sum to reflect dependency changes - Bump Go version from 1.24.5 to 1.25.0 - Upgrade go-ethereum from v1.17.0 to v1.17.3 - Update go-eth-kzg from v1.4.0 to v1.5.0 - Upgrade c-kzg-4844 from v2.1.5 to v2.1.6 - Upgrade opentelemetry packages from v1.39.0 to v1.44.0 - Update golang.org/x/sync from v0.18.0 to v0.19.0 - Update golang.org/x/tools from v0.38.0 to v0.40.0 - Adjust blst version to v0.3.16 --- contracts/cre/gobindings/go.mod | 20 ++++++++--------- contracts/cre/gobindings/go.sum | 40 ++++++++++++++++----------------- 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/contracts/cre/gobindings/go.mod b/contracts/cre/gobindings/go.mod index c299aed09a..4d0131d2e6 100644 --- a/contracts/cre/gobindings/go.mod +++ b/contracts/cre/gobindings/go.mod @@ -1,9 +1,9 @@ module github.com/smartcontractkit/chainlink-evm/contracts/cre/gobindings -go 1.24.5 +go 1.25.0 require ( - github.com/ethereum/go-ethereum v1.17.0 + github.com/ethereum/go-ethereum v1.17.3 github.com/smartcontractkit/chainlink-evm/gethwrappers/helpers v0.0.0-20260113095857-e13e0dd04d9f ) @@ -18,10 +18,10 @@ require ( github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/consensys/gnark-crypto v0.18.1 // indirect - github.com/crate-crypto/go-eth-kzg v1.4.0 // indirect + github.com/crate-crypto/go-eth-kzg v1.5.0 // indirect github.com/deckarep/golang-set/v2 v2.6.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect - github.com/ethereum/c-kzg-4844/v2 v2.1.5 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.6 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect github.com/go-logr/logr v1.4.3 // indirect github.com/go-logr/stdr v1.2.2 // indirect @@ -32,18 +32,18 @@ require ( github.com/pkg/errors v0.9.1 // indirect github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/stephenlacy/go-ethereum-hdwallet v0.0.0-20230913225845-a4fa94429863 // indirect - github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe // indirect + github.com/supranational/blst v0.3.16 // indirect github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect github.com/tyler-smith/go-bip39 v1.1.0 // indirect github.com/zksync-sdk/zksync2-go v1.1.0 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect - go.opentelemetry.io/otel v1.39.0 // indirect - go.opentelemetry.io/otel/metric v1.39.0 // indirect - go.opentelemetry.io/otel/trace v1.39.0 // indirect + go.opentelemetry.io/otel v1.44.0 // indirect + go.opentelemetry.io/otel/metric v1.44.0 // indirect + go.opentelemetry.io/otel/trace v1.44.0 // indirect go.uber.org/multierr v1.11.0 // indirect golang.org/x/crypto v0.48.0 // indirect - golang.org/x/sync v0.18.0 // indirect + golang.org/x/sync v0.19.0 // indirect golang.org/x/sys v0.41.0 // indirect - golang.org/x/tools v0.38.0 // indirect + golang.org/x/tools v0.40.0 // indirect ) diff --git a/contracts/cre/gobindings/go.sum b/contracts/cre/gobindings/go.sum index e6d6a4d30a..bbf22eed49 100644 --- a/contracts/cre/gobindings/go.sum +++ b/contracts/cre/gobindings/go.sum @@ -59,8 +59,8 @@ github.com/consensys/gnark-crypto v0.18.1 h1:RyLV6UhPRoYYzaFnPQA4qK3DyuDgkTgskDd github.com/consensys/gnark-crypto v0.18.1/go.mod h1:L3mXGFTe1ZN+RSJ+CLjUt9x7PNdx8ubaYfDROyp2Z8c= github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/crate-crypto/go-eth-kzg v1.4.0 h1:WzDGjHk4gFg6YzV0rJOAsTK4z3Qkz5jd4RE3DAvPFkg= -github.com/crate-crypto/go-eth-kzg v1.4.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= +github.com/crate-crypto/go-eth-kzg v1.5.0 h1:FYRiJMJG2iv+2Dy3fi14SVGjcPteZ5HAAUe4YWlJygc= +github.com/crate-crypto/go-eth-kzg v1.5.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= @@ -80,12 +80,12 @@ github.com/deepmap/oapi-codegen v1.6.0 h1:w/d1ntwh91XI0b/8ja7+u5SvA4IFfM0UNNLmiD github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5 h1:aVtoLK5xwJ6c5RiqO8g8ptJ5KU+2Hdquf6G3aXiHh5s= -github.com/ethereum/c-kzg-4844/v2 v2.1.5/go.mod h1:u59hRTTah4Co6i9fDWtiCjTrblJv0UwsqZKCc0GfgUs= +github.com/ethereum/c-kzg-4844/v2 v2.1.6 h1:xQymkKCT5E2Jiaoqf3v4wsNgjZLY0lRSkZn27fRjSls= +github.com/ethereum/c-kzg-4844/v2 v2.1.6/go.mod h1:8HMkUZ5JRv4hpw/XUrYWSQNAUzhHMg2UDb/U+5m+XNw= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= -github.com/ethereum/go-ethereum v1.17.0 h1:2D+1Fe23CwZ5tQoAS5DfwKFNI1HGcTwi65/kRlAVxes= -github.com/ethereum/go-ethereum v1.17.0/go.mod h1:2W3msvdosS/MCWytpqTcqgFiRYbTH59FxDJzqah120o= +github.com/ethereum/go-ethereum v1.17.3 h1:Ev/sQHH+UdKZHWjuVzhu2pxhi/sXaPZl23Q+Q5LDd4Q= +github.com/ethereum/go-ethereum v1.17.3/go.mod h1:f2EhRwqewIZkGoQekywI2Y2RZAMTSavLNkD9qItFy1A= github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= github.com/ferranbt/fastssz v0.1.4/go.mod h1:Ea3+oeoRGGLGm5shYAeDgu6PGUlcvQhE2fILyD9+tGg= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= @@ -241,8 +241,8 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U= github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe h1:nbdqkIGOGfUAD54q1s2YBcBz/WcsxCO9HUQ4aGV5hUw= -github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.16 h1:bTDadT+3fK497EvLdWRQEjiGnUtzJ7jjIUMF0jqwYhE= +github.com/supranational/blst v0.3.16/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= @@ -259,14 +259,14 @@ github.com/zksync-sdk/zksync2-go v1.1.0 h1:cRA1GlNrBEwLqvBLq5Xu22YCpbBeUBb4LKx5W github.com/zksync-sdk/zksync2-go v1.1.0/go.mod h1:NWNlQS21isOsSsn+hLRAPpiuv+3P+LcdaZNuRt2T5Yo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= -go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= -go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= -go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= -go.opentelemetry.io/otel/metric v1.39.0/go.mod h1:jrZSWL33sD7bBxg1xjrqyDjnuzTUB0x1nBERXd7Ftcs= -go.opentelemetry.io/otel/sdk v1.39.0 h1:nMLYcjVsvdui1B/4FRkwjzoRVsMK8uL/cj0OyhKzt18= -go.opentelemetry.io/otel/sdk v1.39.0/go.mod h1:vDojkC4/jsTJsE+kh+LXYQlbL8CgrEcwmt1ENZszdJE= -go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= -go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= +go.opentelemetry.io/otel v1.44.0 h1:JjwHmHpA4iZ3wBxluu2fbbE7j4kqlE8jXyAyPXH7HqU= +go.opentelemetry.io/otel v1.44.0/go.mod h1:BMgjTHL9WPRlRjL2oZCBTL4whCGtXch2H4BhOPIAyYc= +go.opentelemetry.io/otel/metric v1.44.0 h1:1w0gILTcHdr3YI+ixLyjemwrVnsMURbTZFrSYCdDdmc= +go.opentelemetry.io/otel/metric v1.44.0/go.mod h1:8O7hanEPBNgEMmybD3s2VBKcgWOCsA6tzHBPODAiquo= +go.opentelemetry.io/otel/sdk v1.40.0 h1:KHW/jUzgo6wsPh9At46+h4upjtccTmuZCFAc9OJ71f8= +go.opentelemetry.io/otel/sdk v1.40.0/go.mod h1:Ph7EFdYvxq72Y8Li9q8KebuYUr2KoeyHx0DRMKrYBUE= +go.opentelemetry.io/otel/trace v1.44.0 h1:jxF5CsGYCe74MCRx2X4g7WsY/VBKRqqpNvXlX/6gtIk= +go.opentelemetry.io/otel/trace v1.44.0/go.mod h1:oLl1jrMQAVo6v3GAggN+1VH9VIz9iUSvW53sW1Q8PIE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= @@ -284,8 +284,8 @@ golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81R golang.org/x/net v0.49.0 h1:eeHFmOGUTtaaPSGNmjBKpbng9MulQsJURQUAfUwY++o= golang.org/x/net v0.49.0/go.mod h1:/ysNB2EvaqvesRkuLAyjI1ycPZlQHM3q01F02UY/MV8= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.18.0 h1:kr88TuHDroi+UVf+0hZnirlk8o8T+4MrK6mr60WkH/I= -golang.org/x/sync v0.18.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= +golang.org/x/sync v0.19.0 h1:vV+1eWNmZ5geRlYjzm2adRgW2/mcpevXNg50YZtPCE4= +golang.org/x/sync v0.19.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -310,8 +310,8 @@ golang.org/x/text v0.34.0/go.mod h1:homfLqTYRFyVYemLBFl5GgL/DWEiH5wcsQ5gSh1yziA= golang.org/x/time v0.9.0 h1:EsRrnYcQiGH+5FfbgvV4AP7qEZstoyrHB0DzarOQ4ZY= golang.org/x/time v0.9.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.38.0 h1:Hx2Xv8hISq8Lm16jvBZ2VQf+RLmbd7wVUsALibYI/IQ= -golang.org/x/tools v0.38.0/go.mod h1:yEsQ/d/YK8cjh0L6rZlY8tgtlKiBNTL14pGDJPJpYQs= +golang.org/x/tools v0.40.0 h1:yLkxfA+Qnul4cs9QA3KnlFu0lVmd8JJfoq+E41uSutA= +golang.org/x/tools v0.40.0/go.mod h1:Ik/tzLRlbscWpqqMRjyWYDisX8bG13FrdXp3o4Sr9lc= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= From d86a1cf37a473118b61fd7059f7033e6e949cf9c Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 25 Jun 2026 16:10:05 -0300 Subject: [PATCH 09/29] Update GETH_VERSION to 1.17.3 across multiple generated-wrapper dependency files --- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 11 files changed, 11 insertions(+), 11 deletions(-) diff --git a/contracts/cre/gobindings/dev/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/contracts/cre/gobindings/dev/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e691b9743a..62460bc8fc 100644 --- a/contracts/cre/gobindings/dev/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/contracts/cre/gobindings/dev/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 message_emitter: ../../solc/dev/MessageEmitter/MessageEmitter.sol/MessageEmitter.abi.json ../../solc/dev/MessageEmitter/MessageEmitter.sol/MessageEmitter.bin 14234aed0e58dbad3581517107bd851cebddc75892050fc207cbfb12dcdfe695 mock_forwarder: ../../solc/dev/MockKeystoneForwarder/MockKeystoneForwarder.sol/MockKeystoneForwarder.abi.json ../../solc/dev/MockKeystoneForwarder/MockKeystoneForwarder.sol/MockKeystoneForwarder.bin c6c9a6e84780eacc6fd358daab8b5f11b3cddfe47416cc84c18b093ce6a65503 reserve_manager: ../../solc/dev/ReserveManager/ReserveManager.sol/ReserveManager.abi.json ../../solc/dev/ReserveManager/ReserveManager.sol/ReserveManager.bin 113a433c32bf094b3ab25bf8c3ae0eddf2e31e4e525b85924c0688fc48148c75 diff --git a/contracts/cre/gobindings/v1/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/contracts/cre/gobindings/v1/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 5e6784eb72..621067df8c 100644 --- a/contracts/cre/gobindings/v1/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/contracts/cre/gobindings/v1/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 balance_reader: ../../solc/v1/BalanceReader/BalanceReader.sol/BalanceReader.abi.json ../../solc/v1/BalanceReader/BalanceReader.sol/BalanceReader.bin a39a8b0ab5c2fbdd3d6dc7208ffa6b777f2d9e0ad0ddd00fdc299e65a782f22b capabilities_registry_wrapper: ../../solc/v1/CapabilitiesRegistry/CapabilitiesRegistry.sol/CapabilitiesRegistry.abi.json ../../solc/v1/CapabilitiesRegistry/CapabilitiesRegistry.sol/CapabilitiesRegistry.bin c5635a7f210b40b64ebcff39a4a816835f3492c029a61a47eae4b138f70dd1e8 feeds_consumer: ../../solc/v1/KeystoneFeedsConsumer/KeystoneFeedsConsumer.sol/KeystoneFeedsConsumer.abi.json ../../solc/v1/KeystoneFeedsConsumer/KeystoneFeedsConsumer.sol/KeystoneFeedsConsumer.bin d91722f385ae2babb6ad31646956e49dd7c7011a2ed7f3d7bfea3fe92794ffa0 diff --git a/contracts/cre/gobindings/v2/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/contracts/cre/gobindings/v2/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 966ed045df..aee3227edd 100644 --- a/contracts/cre/gobindings/v2/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/contracts/cre/gobindings/v2/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,3 +1,3 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 capabilities_registry_wrapper: ../../solc/v2/CapabilitiesRegistry/CapabilitiesRegistry.sol/CapabilitiesRegistry.abi.json ../../solc/v2/CapabilitiesRegistry/CapabilitiesRegistry.sol/CapabilitiesRegistry.bin 4da4a10c2fa6e7fd049c6b2470d1403df9a4a77f516941cfd2d5f1f067a14d8b workflow_registry_wrapper: ../../solc/v2/WorkflowRegistry/WorkflowRegistry.sol/WorkflowRegistry.abi.json ../../solc/v2/WorkflowRegistry/WorkflowRegistry.sol/WorkflowRegistry.bin 1f970e09e9857f220ff9568d43225223380167eeda2dba0ff03d5ce8fca09681 diff --git a/gethwrappers/data-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/data-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 4d8faa1841..b2240a3d31 100644 --- a/gethwrappers/data-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/data-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,3 +1,3 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 bundle_aggregator_proxy: ../../contracts/solc/data-feeds/BundleAggregatorProxy/BundleAggregatorProxy.sol/BundleAggregatorProxy.abi.json ../../contracts/solc/data-feeds/BundleAggregatorProxy/BundleAggregatorProxy.sol/BundleAggregatorProxy.bin b28fb697d1d846523f4552143dc7fb162054d3d387d110c02500203b7cd08b7c data_feeds_cache: ../../contracts/solc/data-feeds/DataFeedsCache/DataFeedsCache.sol/DataFeedsCache.abi.json ../../contracts/solc/data-feeds/DataFeedsCache/DataFeedsCache.sol/DataFeedsCache.bin dc334adf5274f87e5c05e5e6e794b22b1e313d6e8fda18e33699ab07e993cc27 diff --git a/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 711cc481e7..f58f7d3932 100644 --- a/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 functions_allow_list: ../../contracts/solc/functions/TermsOfServiceAllowList/TermsOfServiceAllowList.sol/TermsOfServiceAllowList.abi.json ../../contracts/solc/functions/TermsOfServiceAllowList/TermsOfServiceAllowList.sol/TermsOfServiceAllowList.bin b9a4aeba7da7d3b98e6cf4366d73d03b861232b3b89a53040fedcb0953ccf1d3 functions_client: ../../contracts/solc/functions/FunctionsClient/FunctionsClient.sol/FunctionsClient.abi.json ../../contracts/solc/functions/FunctionsClient/FunctionsClient.sol/FunctionsClient.bin 266c3a9f2b6539e43486af588a7bc3c58694061d7155917c59b106f4217f68e5 functions_client_example: ../../contracts/solc/functions/FunctionsClientExample/FunctionsClientExample.sol/FunctionsClientExample.abi.json ../../contracts/solc/functions/FunctionsClientExample/FunctionsClientExample.sol/FunctionsClientExample.bin e52846aad97167917823e93aa105804e6a0d66acd7d07cc514b5bf4488b0a19f diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 6cc98077c2..ab784ae29e 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ArbitrumModule.abi.json ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ArbitrumModule.bin 9b11a5fbc0c3c2839ba15515eab52ff4d509b918fdc177d454979d69a503bc40 automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c diff --git a/gethwrappers/l2ep/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/l2ep/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 5e21154a0b..b703f11a86 100644 --- a/gethwrappers/l2ep/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/l2ep/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 arbitrum_cross_domain_forwarder: ../../contracts/solc/l2ep/ArbitrumCrossDomainForwarder/ArbitrumCrossDomainForwarder.sol/ArbitrumCrossDomainForwarder.abi.json ../../contracts/solc/l2ep/ArbitrumCrossDomainForwarder/ArbitrumCrossDomainForwarder.sol/ArbitrumCrossDomainForwarder.bin b9a42ecb8b5bcee81fdc33b565422297b4e2163b16afbc1a400ec2f169b54e5c arbitrum_cross_domain_governor: ../../contracts/solc/l2ep/ArbitrumCrossDomainGovernor/ArbitrumCrossDomainGovernor.sol/ArbitrumCrossDomainGovernor.abi.json ../../contracts/solc/l2ep/ArbitrumCrossDomainGovernor/ArbitrumCrossDomainGovernor.sol/ArbitrumCrossDomainGovernor.bin 3ff6d00db86e8abd60ca27a3018806e078c701815fb02b48d3a9f8e3f924d307 arbitrum_sequencer_uptime_feed: ../../contracts/solc/l2ep/ArbitrumSequencerUptimeFeed/ArbitrumSequencerUptimeFeed.sol/ArbitrumSequencerUptimeFeed.abi.json ../../contracts/solc/l2ep/ArbitrumSequencerUptimeFeed/ArbitrumSequencerUptimeFeed.sol/ArbitrumSequencerUptimeFeed.bin 6915fa8112161f20792c33c3e5df4fdd917284f743be05699c54b1f2a0b45910 diff --git a/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a1fe3a0ffa..af7b09a727 100644 --- a/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 channel_config_store: ../../contracts/solc/llo-feeds/v0.5.0/ChannelConfigStore/ChannelConfigStore.sol/ChannelConfigStore.abi.json ../../contracts/solc/llo-feeds/v0.5.0/ChannelConfigStore/ChannelConfigStore.sol/ChannelConfigStore.bin 97c2c6f7d8717ca916c4b0eb82bced7de0bbe22875efabce0de69a6a3cbd0555 channel_config_store_v0_5_0: ../../../contracts/solc/v0.8.19/llo-feeds/v0.5.0/configuration/ChannelConfigStore/ChannelConfigStore.abi ../../../contracts/solc/v0.8.19/llo-feeds/v0.5.0/configuration/ChannelConfigStore/ChannelConfigStore.bin 3fafe83ea21d50488f5533962f62683988ffa6fd1476dccbbb9040be2369cb37 channel_config_verifier_proxy: ../../../contracts/solc/v0.8.19/ChannelVerifierProxy/ChannelVerifierProxy.abi ../../../contracts/solc/v0.8.19/ChannelVerifierProxy/ChannelVerifierProxy.bin 655658e5f61dfadfe3268de04f948b7e690ad03ca45676e645d6cd6018154661 diff --git a/gethwrappers/operatorforwarder/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/operatorforwarder/generation/generated-wrapper-dependency-versions-do-not-edit.txt index ba39f6f515..c3f584bfd7 100644 --- a/gethwrappers/operatorforwarder/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/operatorforwarder/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 authorized_forwarder: ../../contracts/solc/operatorforwarder/AuthorizedForwarder/AuthorizedForwarder.sol/AuthorizedForwarder.abi.json ../../contracts/solc/operatorforwarder/AuthorizedForwarder/AuthorizedForwarder.sol/AuthorizedForwarder.bin c8b082ae6967fc697a4a020fadab8fcddde736a98ee23fa3d17022a5eefe2465 authorized_receiver: ../../contracts/solc/operatorforwarder/AuthorizedReceiver/AuthorizedReceiver.sol/AuthorizedReceiver.abi.json ../../contracts/solc/operatorforwarder/AuthorizedReceiver/AuthorizedReceiver.sol/AuthorizedReceiver.bin 08ae9c84f268395306fa788479d0bbbd59786bf006fdec546f440a357e8082d9 link_token_receiver: ../../contracts/solc/operatorforwarder/LinkTokenReceiver/LinkTokenReceiver.sol/LinkTokenReceiver.abi.json ../../contracts/solc/operatorforwarder/LinkTokenReceiver/LinkTokenReceiver.sol/LinkTokenReceiver.bin 67a7c81f4a692ec93f95ec4b4d179273db0b9c96bf50dfe0cc10475aaf4eece1 diff --git a/gethwrappers/payments/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/payments/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e234c51971..359c17dffa 100644 --- a/gethwrappers/payments/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/payments/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,2 +1,2 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 payment_token_on_ramp: ../../contracts/solc/payments/PaymentTokenOnRamp/PaymentTokenOnRamp.sol/PaymentTokenOnRamp.abi.json ../../contracts/solc/payments/PaymentTokenOnRamp/PaymentTokenOnRamp.sol/PaymentTokenOnRamp.bin 915fee2ec358c7b43e8d2f61052afe666b505a06df09df2dfef4edc3b0defa8a diff --git a/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 15982118bc..f0adf511bc 100644 --- a/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ -GETH_VERSION: 1.17.0 +GETH_VERSION: 1.17.3 aggregator_v3_interface: ../../contracts/solc/shared/AggregatorV3Interface/AggregatorV3Interface.sol/AggregatorV3Interface.abi.json ../../contracts/solc/shared/AggregatorV3Interface/AggregatorV3Interface.sol/AggregatorV3Interface.bin 0294226c10dd4b77239d85074fcf05c39c5cbf513b45bb07f966a8733457d2cb burn_mint_erc20: ../../contracts/solc/shared/BurnMintERC20/BurnMintERC20.sol/BurnMintERC20.abi.json ../../contracts/solc/shared/BurnMintERC20/BurnMintERC20.sol/BurnMintERC20.bin 161d4fc00d3bd8759a82a11d2d0946653ed06853e67359049ac4176288090d22 burn_mint_erc20_pausable_freezable_transparent: ../../contracts/solc/shared/BurnMintERC20PausableFreezableTransparent/BurnMintERC20PausableFreezableTransparent.sol/BurnMintERC20PausableFreezableTransparent.abi.json ../../contracts/solc/shared/BurnMintERC20PausableFreezableTransparent/BurnMintERC20PausableFreezableTransparent.sol/BurnMintERC20PausableFreezableTransparent.bin 6947fcaa97d960921b7af975087b0fd620c179dad30c7dc7a4d1d48b5c8c5ea1 From b0b3031573df972ec93131ee7dc00a5ad07b5a25 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Fri, 26 Jun 2026 10:50:03 -0300 Subject: [PATCH 10/29] Update AutomationReceiver and related files for compatibility with Solidity 0.8.24 - Updated Solidity version in AutomationReceiver and ReceiverTemplate to 0.8.24. - Refactored AutomationReceiver to implement ITypeAndVersion interface. - Added new compilation profile for automation-compile-24 in foundry.toml. - Updated compilation script to reference automation-compile-24 for AutomationReceiver. - Adjusted generated wrapper dependency versions for AutomationReceiver. --- contracts/foundry.toml | 6 ++++ .../native_solc_compile_all_automation | 2 +- .../v0.8/automation/AutomationReceiver.sol | 6 ++-- .../src/v0.8/automation/ReceiverTemplate.sol | 6 ++-- .../automation_receiver.go | 28 +++++++++++++++++-- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 6 files changed, 41 insertions(+), 9 deletions(-) diff --git a/contracts/foundry.toml b/contracts/foundry.toml index 502b7ec736..a283d1e635 100644 --- a/contracts/foundry.toml +++ b/contracts/foundry.toml @@ -73,6 +73,12 @@ optimizer_runs = 1_000_000 src = 'src/v0.8/automation' deny_warnings = false +[profile.automation-compile-24] +solc_version = '0.8.24' +optimizer_runs = 1_000_000 +src = 'src/v0.8/automation' +deny_warnings = false + [profile.l2ep] solc_version = '0.8.24' optimizer_runs = 1_000_000 diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation index a4cf975cf7..71c6bbf75e 100755 --- a/contracts/scripts/native_solc_compile_all_automation +++ b/contracts/scripts/native_solc_compile_all_automation @@ -63,4 +63,4 @@ compileContract automation-compile-23 upkeeps/EthBalanceMonitor compileContract automation-compile-23 v2_3/AutomationUtils2_3 compileContract automation-compile-23 interfaces/v2_3/IAutomationRegistryMaster2_3 compileContract automation-compile-23 testhelpers/MockETHUSDAggregator -compileContract automation-compile-23 AutomationReceiver +compileContract automation-compile-24 AutomationReceiver diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 49b8fc6680..900c8d8904 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -1,6 +1,7 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.19; +pragma solidity ^0.8.24; +import {ITypeAndVersion} from "../shared/interfaces/ITypeAndVersion.sol"; import {ReceiverTemplate} from "./ReceiverTemplate.sol"; /** @@ -19,7 +20,8 @@ import {ReceiverTemplate} from "./ReceiverTemplate.sol"; * * Migration rule of thumb: inbound authorizes the workflow; outbound authorizes the action. */ -contract AutomationReceiver is ReceiverTemplate { +contract AutomationReceiver is ITypeAndVersion, ReceiverTemplate { + string public constant override typeAndVersion = "AutomationReceiver 1.0.0"; mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index 1e8ab75e66..daa80420fe 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; +pragma solidity ^0.8.24; import {IERC165} from "../vendor/IERC165.sol"; import {IReceiver} from "./IReceiver.sol"; -import {Ownable} from "@openzeppelin/contracts@4.8.3/access/Ownable.sol"; +import {Ownable} from "@openzeppelin/contracts@5.3.0/access/Ownable.sol"; /// @title ReceiverTemplate - Abstract receiver with optional permission controls /// @notice Provides flexible, updatable security checks for receiving workflow reports @@ -33,7 +33,7 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { constructor( address _forwarderAddress - ) Ownable() { + ) Ownable(msg.sender) { if (_forwarderAddress == address(0)) revert InvalidForwarderAddress(); s_forwarderAddress = _forwarderAddress; emit ForwarderAddressUpdated(address(0), _forwarderAddress); diff --git a/gethwrappers/generated/automation_receiver/automation_receiver.go b/gethwrappers/generated/automation_receiver/automation_receiver.go index 30002b1ed1..64f94b0f4e 100644 --- a/gethwrappers/generated/automation_receiver/automation_receiver.go +++ b/gethwrappers/generated/automation_receiver/automation_receiver.go @@ -31,8 +31,8 @@ var ( ) var AutomationReceiverMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", - Bin: "0x608060405234801561001057600080fd5b5060405162001a2738038062001a2783398101604081905261003191610101565b8061003b336100b1565b6001600160a01b0381166100615760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040516000907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a35050610131565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561011357600080fd5b81516001600160a01b038116811461012a57600080fd5b9392505050565b6118e680620001416000396000f3fe608060405234801561001057600080fd5b50600436106100f55760003560e01c80639c1c77ca11610097578063d60c884b11610066578063d60c884b146102ac578063d777cc6d146102bf578063f2fde38b146102d2578063f5c793ef146102e557600080fd5b80639c1c77ca14610224578063a619d81814610237578063bc1fc27a14610286578063c3c44ac21461029957600080fd5b8063715018a6116100d3578063715018a61461017f578063797c8d6914610189578063805f2132146101f35780638da5cb5b1461020657600080fd5b806301ffc9a7146100fa5780633397cf67146101225780633441856f14610161575b600080fd5b61010d61010836600461140a565b6102f6565b60405190151581526020015b60405180910390f35b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610119565b60015473ffffffffffffffffffffffffffffffffffffffff1661013c565b61018761038f565b005b61010d61019736600461144e565b73ffffffffffffffffffffffffffffffffffffffff821660009081526004602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101876102013660046114cc565b6103a3565b60005473ffffffffffffffffffffffffffffffffffffffff1661013c565b610187610232366004611538565b610765565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff000000000000000000000000000000000000000000009091168152602001610119565b610187610294366004611586565b610874565b6101876102a73660046115c8565b610af6565b6101876102ba3660046115e1565b610b37565b6101876102cd3660046115e1565b610bb6565b6101876102e03660046115e1565b610ce4565b600354604051908152602001610119565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f805f213200000000000000000000000000000000000000000000000000000000148061038957507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b610397610d9b565b6103a16000610e1c565b565b60015473ffffffffffffffffffffffffffffffffffffffff16158015906103e2575060015473ffffffffffffffffffffffffffffffffffffffff163314155b15610440576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b600354151580610467575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806104b0575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b156107555760008060006104f987878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e9192505050565b60035492955090935091501580159061051457506003548314155b15610559576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610437918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff161580159061059b575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b156105f6576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610437565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016156107515760025473ffffffffffffffffffffffffffffffffffffffff1661068a576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610751576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610437565b5050505b61075f8282610eaa565b50505050565b61076d610d9b565b73ffffffffffffffffffffffffffffffffffffffff83166107ba576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff831660008181526004602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b61087c610d9b565b60025474010000000000000000000000000000000000000000900460b01b600082900361091f57600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040516000907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b6000600284846040516109339291906115fe565b602060405180830381855afa158015610950573d6000803e3d6000fd5b5050506040513d601f19601f82011682018060405250810190610973919061160e565b905060006109a18260405160200161098d91815260200190565b604051602081830303815290604052611178565b60408051600a8082528183019092529192506000919060208201818036833701905050905060005b600a811015610a42578281815181106109e4576109e4611656565b602001015160f81c60f81b828281518110610a0157610a01611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080610a3a816116b4565b9150506109c9565b50610a4c816116ec565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa590600090a3505050505050565b610afe610d9b565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b0390600090a35050565b610b3f610d9b565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad3190600090a35050565b610bbe610d9b565b60015473ffffffffffffffffffffffffffffffffffffffff908116908216610c6e577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7604051610c659060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e90600090a35050565b610cec610d9b565b73ffffffffffffffffffffffffffffffffffffffff8116610d8f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610437565b610d9881610e1c565b50565b60005473ffffffffffffffffffffffffffffffffffffffff1633146103a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610437565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b600080610eb98385018561173c565b909250905073ffffffffffffffffffffffffffffffffffffffff8216610f0b576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015610f47576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff841660009081526004835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff16611018576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610437565b6000808473ffffffffffffffffffffffffffffffffffffffff16846040516110409190611842565b6000604051808303816000865af19150503d806000811461107d576040519150601f19603f3d011682016040523d82523d6000602084013e611082565b606091505b5091509150811561110057827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb884836040516110f3919061185e565b60405180910390a361116f565b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b683604051611166919061185e565b60405180910390a35b50505050505050565b606060008251600261118a91906118af565b67ffffffffffffffff8111156111a2576111a2611627565b6040519080825280601f01601f1916602001820160405280156111cc576020820181803683370190505b50905060005b83518110156113ce576040518060400160405280601081526020017f3031323334353637383961626364656600000000000000000000000000000000815250600485838151811061122557611225611656565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c90811061126557611265611656565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826112988360026118af565b815181106112a8576112a8611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506040518060400160405280601081526020017f303132333435363738396162636465660000000000000000000000000000000081525084828151811061131f5761131f611656565b602091010151815160f89190911c600f1690811061133f5761133f611656565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826113728360026118af565b61137d9060016118c6565b8151811061138d5761138d611656565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806113c6816116b4565b9150506111d2565b5092915050565b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461140557600080fd5b919050565b60006020828403121561141c57600080fd5b611425826113d5565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81168114610d9857600080fd5b6000806040838503121561146157600080fd5b823561146c8161142c565b915061147a602084016113d5565b90509250929050565b60008083601f84011261149557600080fd5b50813567ffffffffffffffff8111156114ad57600080fd5b6020830191508360208285010111156114c557600080fd5b9250929050565b600080600080604085870312156114e257600080fd5b843567ffffffffffffffff808211156114fa57600080fd5b61150688838901611483565b9096509450602087013591508082111561151f57600080fd5b5061152c87828801611483565b95989497509550505050565b60008060006060848603121561154d57600080fd5b83356115588161142c565b9250611566602085016113d5565b91506040840135801515811461157b57600080fd5b809150509250925092565b6000806020838503121561159957600080fd5b823567ffffffffffffffff8111156115b057600080fd5b6115bc85828601611483565b90969095509350505050565b6000602082840312156115da57600080fd5b5035919050565b6000602082840312156115f357600080fd5b81356114258161142c565b8183823760009101908152919050565b60006020828403121561162057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036116e5576116e5611685565b5060010190565b6000815160208301517fffffffffffffffffffff000000000000000000000000000000000000000000008082169350600a83101561173457808184600a0360031b1b83161693505b505050919050565b6000806040838503121561174f57600080fd5b823561175a8161142c565b9150602083013567ffffffffffffffff8082111561177757600080fd5b818501915085601f83011261178b57600080fd5b81358181111561179d5761179d611627565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156117e3576117e3611627565b816040528281528860208487010111156117fc57600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b60005b83811015611839578181015183820152602001611821565b50506000910152565b6000825161185481846020870161181e565b9190910192915050565b602081526000825180602084015261187d81604085016020870161181e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b808202811582820484141761038957610389611685565b808201808211156103895761038961168556fea164736f6c6343000813000a", + ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"typeAndVersion\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", + Bin: "0x608060405234801562000010575f80fd5b506040516200198a3803806200198a83398101604081905262000033916200012c565b8033806200005a57604051631e4fbdf760e01b81525f600482015260240160405180910390fd5b6200006581620000dd565b506001600160a01b0381166200008d5760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040515f907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a350506200015b565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f602082840312156200013d575f80fd5b81516001600160a01b038116811462000154575f80fd5b9392505050565b61182180620001695f395ff3fe608060405234801561000f575f80fd5b50600436106100fb575f3560e01c80639c1c77ca11610093578063d60c884b11610063578063d60c884b146102f8578063d777cc6d1461030b578063f2fde38b1461031e578063f5c793ef14610331575f80fd5b80639c1c77ca14610270578063a619d81814610283578063bc1fc27a146102d2578063c3c44ac2146102e5575f80fd5b8063715018a6116100ce578063715018a6146101cd578063797c8d69146101d7578063805f2132146102405780638da5cb5b14610253575f80fd5b806301ffc9a7146100ff578063181f5a77146101275780633397cf67146101705780633441856f146101af575b5f80fd5b61011261010d36600461139f565b610342565b60405190151581526020015b60405180910390f35b6101636040518060400160405280601881526020017f4175746f6d6174696f6e526563656976657220312e302e30000000000000000081525081565b60405161011e919061142a565b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161011e565b60015473ffffffffffffffffffffffffffffffffffffffff1661018a565b6101d56103da565b005b6101126101e536600461145d565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526004602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101d561024e3660046114d5565b6103ed565b5f5473ffffffffffffffffffffffffffffffffffffffff1661018a565b6101d561027e36600461153c565b6107ac565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff00000000000000000000000000000000000000000000909116815260200161011e565b6101d56102e0366004611586565b6108ba565b6101d56102f33660046115c5565b610b28565b6101d56103063660046115dc565b610b68565b6101d56103193660046115dc565b610be6565b6101d561032c3660046115dc565b610d13565b60035460405190815260200161011e565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f805f21320000000000000000000000000000000000000000000000000000000014806103d457507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b6103e2610d76565b6103eb5f610dc8565b565b60015473ffffffffffffffffffffffffffffffffffffffff161580159061042c575060015473ffffffffffffffffffffffffffffffffffffffff163314155b1561048a576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b6003541515806104b1575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806104fa575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b1561079c575f805f61054087878080601f0160208091040260200160405190810160405280939291908181526020018383808284375f92019190915250610e3c92505050565b60035492955090935091501580159061055b57506003548314155b156105a0576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610481918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff16158015906105e2575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b1561063d576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610481565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016156107985760025473ffffffffffffffffffffffffffffffffffffffff166106d1576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610798576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610481565b5050505b6107a68282610e55565b50505050565b6107b4610d76565b73ffffffffffffffffffffffffffffffffffffffff8316610801576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83165f8181526004602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b6108c2610d76565b60025474010000000000000000000000000000000000000000900460b01b5f82900361096357600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040515f907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b5f600284846040516109769291906115f7565b602060405180830381855afa158015610991573d5f803e3d5ffd5b5050506040513d601f19601f820116820180604052508101906109b49190611606565b90505f6109e1826040516020016109cd91815260200190565b60405160208183030381529060405261111c565b60408051600a8082528183019092529192505f91906020820181803683370190505090505f5b600a811015610a7557828181518110610a2257610a2261164a565b602001015160f81c60f81b828281518110610a3f57610a3f61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101610a07565b50610a7f81611677565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5905f90a3505050505050565b610b30610d76565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03905f90a35050565b610b70610d76565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31905f90a35050565b610bee610d76565b60015473ffffffffffffffffffffffffffffffffffffffff908116908216610c9e577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7604051610c959060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e905f90a35050565b610d1b610d76565b73ffffffffffffffffffffffffffffffffffffffff8116610d6a576040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081525f6004820152602401610481565b610d7381610dc8565b50565b5f5473ffffffffffffffffffffffffffffffffffffffff1633146103eb576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610481565b5f805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b5f80610e63838501856116c6565b909250905073ffffffffffffffffffffffffffffffffffffffff8216610eb5576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015610ef1576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff84165f9081526004835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff16610fc1576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610481565b5f808473ffffffffffffffffffffffffffffffffffffffff1684604051610fe891906117a2565b5f604051808303815f865af19150503d805f8114611021576040519150601f19603f3d011682016040523d82523d5f602084013e611026565b606091505b509150915081156110a457827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb88483604051611097919061142a565b60405180910390a3611113565b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b68360405161110a919061142a565b60405180910390a35b50505050505050565b60605f8251600261112d91906117ea565b67ffffffffffffffff8111156111455761114561161d565b6040519080825280601f01601f19166020018201604052801561116f576020820181803683370190505b5090505f5b8351811015611364576040518060400160405280601081526020017f303132333435363738396162636465660000000000000000000000000000000081525060048583815181106111c7576111c761164a565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c9081106112075761120761164a565b01602001517fff00000000000000000000000000000000000000000000000000000000000000168261123a8360026117ea565b8151811061124a5761124a61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053506040518060400160405280601081526020017f30313233343536373839616263646566000000000000000000000000000000008152508482815181106112c0576112c061164a565b602091010151815160f89190911c600f169081106112e0576112e061164a565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826113138360026117ea565b61131e906001611801565b8151811061132e5761132e61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101611174565b5092915050565b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461139a575f80fd5b919050565b5f602082840312156113af575f80fd5b6113b88261136b565b9392505050565b5f5b838110156113d95781810151838201526020016113c1565b50505f910152565b5f81518084526113f88160208601602086016113bf565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081525f6113b860208301846113e1565b73ffffffffffffffffffffffffffffffffffffffff81168114610d73575f80fd5b5f806040838503121561146e575f80fd5b82356114798161143c565b91506114876020840161136b565b90509250929050565b5f8083601f8401126114a0575f80fd5b50813567ffffffffffffffff8111156114b7575f80fd5b6020830191508360208285010111156114ce575f80fd5b9250929050565b5f805f80604085870312156114e8575f80fd5b843567ffffffffffffffff808211156114ff575f80fd5b61150b88838901611490565b90965094506020870135915080821115611523575f80fd5b5061153087828801611490565b95989497509550505050565b5f805f6060848603121561154e575f80fd5b83356115598161143c565b92506115676020850161136b565b91506040840135801515811461157b575f80fd5b809150509250925092565b5f8060208385031215611597575f80fd5b823567ffffffffffffffff8111156115ad575f80fd5b6115b985828601611490565b90969095509350505050565b5f602082840312156115d5575f80fd5b5035919050565b5f602082840312156115ec575f80fd5b81356113b88161143c565b818382375f9101908152919050565b5f60208284031215611616575f80fd5b5051919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f815160208301517fffffffffffffffffffff000000000000000000000000000000000000000000008082169350600a8310156116be57808184600a0360031b1b83161693505b505050919050565b5f80604083850312156116d7575f80fd5b82356116e28161143c565b9150602083013567ffffffffffffffff808211156116fe575f80fd5b818501915085601f830112611711575f80fd5b8135818111156117235761172361161d565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156117695761176961161d565b81604052828152886020848701011115611781575f80fd5b826020860160208301375f6020848301015280955050505050509250929050565b5f82516117b38184602087016113bf565b9190910192915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b80820281158282048414176103d4576103d46117bd565b808201808211156103d4576103d46117bd56fea164736f6c6343000818000a", } var AutomationReceiverABI = AutomationReceiverMetaData.ABI @@ -325,6 +325,28 @@ func (_AutomationReceiver *AutomationReceiverCallerSession) SupportsInterface(in return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) } +func (_AutomationReceiver *AutomationReceiverCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) TypeAndVersion() (string, error) { + return _AutomationReceiver.Contract.TypeAndVersion(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) TypeAndVersion() (string, error) { + return _AutomationReceiver.Contract.TypeAndVersion(&_AutomationReceiver.CallOpts) +} + func (_AutomationReceiver *AutomationReceiverTransactor) OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) { return _AutomationReceiver.contract.Transact(opts, "onReport", metadata, report) } @@ -1710,6 +1732,8 @@ type AutomationReceiverInterface interface { SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + TypeAndVersion(opts *bind.CallOpts) (string, error) + OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index ab784ae29e..ed149b5c9e 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 -automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin 73808cf06a4320a9da36308fdeb8640077c633cbc7515d6dc05c55d9469046be +automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin fd174c01998b44055471666fdf1d31e247ce9b32f9fcf920710cc7026cfbeec0 automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef From cef3c8bb375f137b753770dd0b7f5eb2784de04d Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Wed, 8 Jul 2026 14:36:53 -0300 Subject: [PATCH 11/29] Update AutomationReceiver contract --- .../v0.8/automation/AutomationReceiver.sol | 433 +++++- contracts/src/v0.8/automation/IERC165.sol | 12 + contracts/src/v0.8/automation/IReceiver.sol | 9 +- .../src/v0.8/automation/ReceiverTemplate.sol | 117 +- .../automation_receiver.go | 1247 +++++++++++++++-- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 6 files changed, 1608 insertions(+), 212 deletions(-) create mode 100644 contracts/src/v0.8/automation/IERC165.sol diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 900c8d8904..ecfcf4e099 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.24; +pragma solidity 0.8.26; -import {ITypeAndVersion} from "../shared/interfaces/ITypeAndVersion.sol"; -import {ReceiverTemplate} from "./ReceiverTemplate.sol"; +import "./ReceiverTemplate.sol"; +import {Pausable} from "@openzeppelin/contracts/utils/Pausable.sol"; /** * @title AutomationReceiver @@ -10,66 +10,381 @@ import {ReceiverTemplate} from "./ReceiverTemplate.sol"; * * @dev Two independent authorization layers protect this contract: * - * 1. INBOUND (inherited from {ReceiverTemplate}) — answers "who may deliver a report?": - * the CRE Forwarder address plus the optional workflowId / workflowName / workflowOwner - * identity checks. + * 1. INBOUND — answers "who may deliver a report?": + * a) {ReceiverTemplate} enforces the CRE Forwarder address check and optional + * workflowId / workflowName / workflowOwner identity checks. + * b) {_processReport} additionally requires that the forwarder is non-zero (closing + * the gap left by `ReceiverTemplate.setForwarderAddress` which permits address(0)) + * and that at least one complete workflow identity option is configured before any + * report is accepted: either (1) workflowId is set, or (2) both workflowOwner and + * workflowName are set. Neither option alone is sufficient for option 2. * * 2. OUTBOUND (this contract) — answers "what may a report make this contract do?": - * a closed-by-default allowlist of (target, function-selector) pairs. The owner must - * explicitly allow each (target, selector) before it can be executed. + * a closed-by-default allowlist of (target, function-selector) pairs. The inbound checks + * do NOT constrain the `(target, data)` a report carries, so without this layer any + * authorized report could call any contract/function this receiver is trusted by. The + * owner must explicitly allow each (target, selector) before it can be executed. * * Migration rule of thumb: inbound authorizes the workflow; outbound authorizes the action. */ -contract AutomationReceiver is ITypeAndVersion, ReceiverTemplate { - string public constant override typeAndVersion = "AutomationReceiver 1.0.0"; - mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; - - event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); - event CallFailed(address indexed target, bytes4 indexed selector, bytes reason); - event CallAllowedSet(address indexed target, bytes4 indexed selector, bool allowed); - - error InvalidTargetAddress(); - error MissingSelector(); - error CallNotAllowed(address target, bytes4 selector); - - constructor( - address _forwarder - ) ReceiverTemplate(_forwarder) {} - - /// @notice Allow or disallow the receiver to call `selector` on `target`. Owner-only. - function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { - if (target == address(0)) revert InvalidTargetAddress(); - s_callAllowed[target][selector] = allowed; - emit CallAllowedSet(target, selector, allowed); - } - - /// @notice Returns whether the receiver may call `selector` on `target`. - function isCallAllowed(address target, bytes4 selector) external view returns (bool) { - return s_callAllowed[target][selector]; - } - - /// @notice Decodes and executes the call encoded in the CRE report. - /// @param report ABI-encoded (address target, bytes data). - function _processReport( - bytes calldata report - ) internal override { - (address target, bytes memory data) = abi.decode(report, (address, bytes)); - - if (target == address(0)) revert InvalidTargetAddress(); - if (data.length < 4) revert MissingSelector(); - - bytes4 selector; - assembly { - selector := mload(add(data, 0x20)) +contract AutomationReceiver is ReceiverTemplate, Pausable { + // Non-target gas costs reserved by the guard (gasleft() < required). + // GAS_OVERHEAD covers only the post-check path: everything from the gasleft() + // comparison through function return. The s_consumerGasLimit SLOAD immediately + // preceding the check is NOT included — it is already reflected in the lower + // gasleft() value at the check point and must not be double-counted. + // + // [Post-check — must complete with remaining gas at the guard point:] + // Pre-call ops (GAS, ADD, LT, JUMPI, stack) ~50 + // CALL to target (cold account access — in production ~2,600 + // setCallAllowed runs in an earlier transaction, so + // the target account has not yet been touched in the + // delivery transaction and the CALL pays the full + // EIP-2929 cold-access surcharge, not the ~100 warm rate) + // Post-call (success flag, JUMPI, LOG3) ~2,200 + // ├─ LOG3 base + 3 topics (375 + 3×375) 1,500 + // ├─ LOG3 data (64 B ABI-encoded empty bytes) 512 + // └─ misc (returnData mem, JUMPI, stack) 188 + // Misc stack / memory ~50 + // Subtotal: ~4,900 + // Conservative headroom (future opcode repricing, ~2,100 + // estimation error) + // Total: ~7,000 + // + // EIP-150 (63/64 rule): a CALL can forward at most 63/64 of available gas. + // Without the `consumerGasLimit / 63` term, the guard under-provisions whenever + // consumerGasLimit > 63 × GAS_OVERHEAD (~441,000). _processReport therefore adds + // consumerGasLimit / 63 to `required` dynamically so that: + // 63/64 × available ≥ consumerGasLimit + // + // Pre-guard overhead (paid BEFORE the check point, so NOT part of `required`): + // Up to four cold SLOADs in ReceiverTemplate.onReport when identity checks are + // active (s_forwarderAddress, s_expectedWorkflowId, s_expectedAuthor, + // s_expectedWorkflowName: 4 × 2,100 = 8,400 gas), warm re-reads of those slots + // in _processReport (~400 gas), abi.decode of the report (~300 gas), the cold + // nested-mapping read of s_callAllowed (~4,200 gas on first access), a cold + // s_consumerGasLimit SLOAD (~2,100 gas), and paused() (~2,100 gas cold) add up to + // ~17,500 gas on the first delivery to a pair. After slots warm, pre-guard drops to + // ~5,500 gas. When the block-number monotonicity check is enabled for a pair, budget + // a further ~10,000 gas for its two cold SLOADs and the advancing SSTORE. + // + // This pre-guard gas is intentionally NOT added to `required` and needs no per-feature constant: + // it is spent before `gasleft()` is read, so the guard already sees it (it observes the reduced + // remaining gas) and cannot manufacture it. Adding it to `required` would double-count and cause + // spurious InsufficientGas reverts. The only caller-side action is to size writeGasLimit to cover + // this pre-guard overhead on top of consumerGasLimit + GAS_OVERHEAD (see README Gas Limit + // section). Under-budgeting fails cleanly (InsufficientGas if the guard is reached, otherwise + // OOG) — both are recorded by the Forwarder as retryable, so this is a tuning, not a safety, + // concern. + uint256 private constant GAS_OVERHEAD = 7000; + + /// @notice Closed-by-default allowlist of callable (target, selector) pairs. + mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; + + /// @notice Per-(target, selector) minimum gas the consumer needs to execute. 0 = no limit. + mapping(address target => mapping(bytes4 selector => uint256 gasLimit)) private s_consumerGasLimit; + + /// @notice Opt-in per-(target, selector) block-number monotonicity switch. Closed by default. + mapping(address target => mapping(bytes4 selector => bool enabled)) private s_blockNumberCheckEnabled; + + /// @notice Highest report block number accepted so far for a (target, selector) pair. Doubles as + /// the configurable initial floor set by {setBlockNumberCheck}. + mapping(address target => mapping(bytes4 selector => uint256 blockNumber)) private s_lastReportBlock; + /// @notice While paused, controls how incoming reports are handled. The owner picks the mode + /// at {pause} time: true = reverts (reports stay unconsumed and retryable, resuming + /// after {unpause}); false = the report is consumed (dropped, not retried). Only + /// meaningful while {paused} is true. + bool private s_retryableWhilePaused; + + /// @notice Emitted when a target call succeeds. + event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); + /// @notice Emitted when an allowed target call reverts. The report is still consumed. + event CallFailed(address indexed target, bytes4 indexed selector, bytes reason); + /// @notice Emitted when the owner updates the outbound allowlist. + event CallAllowedSet(address indexed target, bytes4 indexed selector, bool allowed); + /// @notice Emitted when the owner updates the consumer gas limit for a (target, selector) pair. + event ConsumerGasLimitSet(address indexed target, bytes4 indexed selector, uint256 previousLimit, uint256 newLimit); + /// @notice Emitted when the owner enables/disables the block-number monotonicity check for a pair. + /// When enabled, `initialBlockNumber` is the floor the next report must meet or exceed. + event BlockNumberCheckSet(address indexed target, bytes4 indexed selector, bool enabled, uint256 initialBlockNumber); + /// @notice Emitted when a report is skipped because its block number is older than the last + /// accepted one for the pair. The report is consumed (not reverted), mirroring + /// Chainlink Automation's fire-and-forget semantics. + event StaleReportSkipped(address indexed target, bytes4 indexed selector, uint256 reportBlockNumber, uint256 lastReportBlock); + /// @notice Emitted when a report is dropped (consumed, not retried) because the receiver is + /// paused in non-retryable mode (see {pause}). + event ReportSkippedWhilePaused(); + + /// @notice Thrown when the decoded target is the zero address. + error InvalidTargetAddress(); + /// @notice Thrown when the target address has no deployed code (EOA, mistyped address, or never-deployed contract). + error TargetHasNoCode(address target); + /// @notice Thrown when the report carries fewer than 4 bytes of calldata (no selector). + error MissingSelector(); + /// @notice Thrown when (target, selector) is not on the outbound allowlist. + error CallNotAllowed(address target, bytes4 selector); + /// @notice Thrown when there is not enough gas to safely forward consumerGasLimit to the target. + /// Causes the forwarder to record the transmission as failed so it can be retried. + error InsufficientGas(uint256 available, uint256 required); + /// @notice Thrown when onReport is called without a complete workflow identity configuration. + /// The receiver requires at least one of the two valid options to be satisfied + /// (satisfying both is also fine): + /// (1) workflowId is set, or (2) both workflowOwner and workflowName are set. + /// Without at least one complete option the receiver cannot be bound to a specific + /// workflow and would accept reports from any DON-signed payload. + error WorkflowIdentityNotConfigured(); + + constructor(address _forwarder) ReceiverTemplate(_forwarder) {} + + /// @notice Emergency stop: halt all report processing until {unpause} is called. Owner-only. + /// @dev Global equivalent of Chainlink Automation's registry-wide pause. DON pause/delete only + /// stops NEW reports; already-signed reports remain permissionlessly deliverable, and this + /// on-chain switch also rejects those in-flight reports. The owner chooses, per pause, how + /// reports that arrive while paused are handled via `retryable`: + /// - `retryable = true`: `_processReport` reverts with `EnforcedPause`. The revert bubbles + /// up through `onReport`, so the CRE Forwarder records the transmission as failed and it + /// stays retryable — pending reports resume delivery once {unpause} is called. + /// - `retryable = false`: `_processReport` emits `ReportSkippedWhilePaused` and returns, + /// consuming the report. Such reports are dropped and will NOT be redelivered after + /// {unpause}. Use this when a backlog of retried reports would be undesirable. + /// @param retryable Whether reports delivered while paused should remain retryable (true) or be + /// dropped (false). The chosen mode applies until the next {pause} or {unpause}. + function pause(bool retryable) external onlyOwner { + s_retryableWhilePaused = retryable; + _pause(); + } + + /// @notice Resume report processing after a {pause}. Owner-only. + function unpause() external onlyOwner { + _unpause(); + } + + /// @notice Returns the pause mode selected at the last {pause}: true if reports delivered while + /// paused revert (retryable), false if they are dropped. Only meaningful while paused. + function retryableWhilePaused() external view returns (bool) { + return s_retryableWhilePaused; + } + + /// @notice Allow or disallow the receiver to call `selector` on `target`. + /// @dev Closed by default. Register every (target, selector) the migrated upkeep needs, + /// e.g. `performUpkeep(bytes)` for custom-logic/log upkeeps, or your specific + /// time-based function. Owner-only. + /// When `allowed` is true, validates that `target` has deployed code at the time of + /// registration; passing an EOA, a mistyped address, or a never-deployed address reverts + /// with `TargetHasNoCode`. The check is skipped when `allowed` is false so that an + /// allowlist entry can always be revoked, even if the target has since self-destructed + /// and its code has become empty. + /// @param target The contract the receiver is permitted to call. + /// @param selector The 4-byte function selector permitted on `target`. + /// @param allowed True to permit, false to revoke. + function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { + if (target == address(0)) { + revert InvalidTargetAddress(); + } + if (allowed && target.code.length == 0) { + revert TargetHasNoCode(target); + } + s_callAllowed[target][selector] = allowed; + emit CallAllowedSet(target, selector, allowed); + } + + /// @notice Returns whether the receiver may call `selector` on `target`. + function isCallAllowed(address target, bytes4 selector) external view returns (bool) { + return s_callAllowed[target][selector]; } - if (!s_callAllowed[target][selector]) revert CallNotAllowed(target, selector); - - // solhint-disable-next-line avoid-low-level-calls - (bool success, bytes memory returnData) = target.call(data); - if (success) { - emit CallExecuted(target, selector, returnData); - } else { - emit CallFailed(target, selector, returnData); + + /// @notice Set the minimum gas required to execute `selector` on `target`. + /// @dev When non-zero, `_processReport` will revert with `InsufficientGas` before calling + /// the target if available gas is below `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. + /// The `gasLimit / 63` term compensates for the EIP-150 (63/64) rule: a CALL can + /// forward at most 63/64 of the available gas, so without this buffer a high gas limit + /// would cause the target to receive less than `gasLimit`. This causes the CRE + /// Forwarder to record the transmission as failed (retryable) rather than permanently + /// consuming the report. Set this to the `performGasLimit` tuned in Automation for the + /// specific function being migrated. Each (target, selector) pair has its own limit. + /// Zero (the default) disables the guard for that pair and preserves fire-and-forget. + /// Note: the on-chain formula only covers costs from the guard check onward. The + /// workflow's writeGasLimit must also budget for pre-guard overhead (~17,500 gas + /// on the first delivery to a pair, ~5,500 gas thereafter) on top of this limit. + /// @param target The contract the limit applies to. Must not be the zero address. + /// @param selector The 4-byte function selector the limit applies to. + /// @param gasLimit Minimum gas required by the consumer. 0 = no guard. + function setConsumerGasLimit(address target, bytes4 selector, uint256 gasLimit) external onlyOwner { + if (target == address(0)) revert InvalidTargetAddress(); + uint256 previous = s_consumerGasLimit[target][selector]; + s_consumerGasLimit[target][selector] = gasLimit; + emit ConsumerGasLimitSet(target, selector, previous, gasLimit); + } + + /// @notice Returns the configured consumer gas limit for a (target, selector) pair (0 = no guard). + function getConsumerGasLimit(address target, bytes4 selector) external view returns (uint256) { + return s_consumerGasLimit[target][selector]; + } + + /// @notice Enable or disable the block-number monotonicity (staleness) check for a (target, selector). + /// @dev Closed by default. When enabled, `_processReport` rejects any report whose encoded block + /// number is strictly less than the last accepted one for the pair (CLA-parity: a report at + /// the same block is still accepted). Stale reports are consumed, not reverted, so the + /// forwarder does not pointlessly retry an always-stale delivery. + /// + /// Under Chainlink Automation the registry rejected any report whose trigger block preceded + /// the last performed block. The CRE delivery path does not preserve this ordering, so this + /// opt-in check restores it for conditional-trigger / log upkeeps that relied on it. The + /// workflow always encodes a block number in the report payload, so this can be turned on + /// later without any workflow change. + /// + /// When enabling, the initial floor is configurable: + /// - `initialBlockNumber == 0`: snapshot the current `block.number` as the floor. Note this + /// does NOT reject reports minted between deployment/config and the moment this check is + /// enabled if they carry a block number above the snapshot; prefer an explicit floor when + /// that matters. + /// - `initialBlockNumber != 0`: use the provided value as the floor. + /// The very first accepted report must have a block number >= this floor. + /// + /// Disabling (enabled = false) resets the floor to 0, so out-of-order reports execute + /// again going forward. This is NOT retroactive: a report already rejected as stale while + /// the check was enabled was consumed at that moment (see `StaleReportSkipped`) and is gone + /// — the CRE Forwarder does not hold it for redelivery. Turning the check off cannot revive + /// it; only reports the workflow re-submits after disabling will be considered. + /// Each (target, selector) pair is configured independently. Owner-only. + /// @param target The contract the check applies to. Must not be the zero address. + /// @param selector The 4-byte function selector the check applies to. + /// @param enabled True to enable the check, false to disable it (and clear the stored floor). + /// @param initialBlockNumber Floor for the first report when enabling; 0 snapshots `block.number`. + function setBlockNumberCheck(address target, bytes4 selector, bool enabled, uint256 initialBlockNumber) + external + onlyOwner + { + if (target == address(0)) revert InvalidTargetAddress(); + s_blockNumberCheckEnabled[target][selector] = enabled; + uint256 floor = enabled ? (initialBlockNumber == 0 ? block.number : initialBlockNumber) : 0; + s_lastReportBlock[target][selector] = floor; + emit BlockNumberCheckSet(target, selector, enabled, floor); + } + + /// @notice Returns the block-number monotonicity configuration for a (target, selector) pair. + /// @return enabled Whether the check is active. + /// @return lastReportBlock The highest report block number accepted so far (or the floor set when + /// the check was enabled, if no report has been accepted since). + function getBlockNumberCheck(address target, bytes4 selector) + external + view + returns (bool enabled, uint256 lastReportBlock) + { + return (s_blockNumberCheckEnabled[target][selector], s_lastReportBlock[target][selector]); + } + + /// @notice Decodes and executes the call on the target contract. + /// @param report ABI-encoded (address target, uint256 blockNumber, bytes data), where + /// `blockNumber` is the block the report was produced for (used only by the opt-in + /// monotonicity check) and `data` is a full function call (4-byte selector followed by its + /// arguments) executed as `target.call(data)`. + /// @dev Two pre-conditions are enforced before any decoding: + /// 1. The forwarder address must not be zero. `ReceiverTemplate.setForwarderAddress` + /// does not block address(0), so this guard closes that gap: if the owner ever + /// sets the forwarder to zero (disabling the caller check in onReport), every + /// subsequent report delivery is rejected here instead. + /// 2. A complete workflow identity option must be configured. Two options are accepted: + /// (a) workflowId is set — binds the receiver to one specific workflow instance; or + /// (b) both workflowOwner and workflowName are set — binds the receiver to a named + /// workflow from a specific owner. Either piece of option (b) alone is insufficient: + /// owner alone allows any workflow from that owner; name alone is globally ambiguous. + /// Requiring a complete option closes the cross-receiver replay vector from audit M-02. + /// Authorization failures (zero target, missing selector, not-allowlisted) revert loudly — + /// they indicate misconfiguration or a malformed report. Execution failures (an allowed call that + /// reverts) are swallowed: `CallFailed` is emitted and the report is consumed, matching + /// Chainlink Automation's fire-and-forget semantics where the next trigger re-evaluates + /// eligibility. + /// Staleness: when the block-number monotonicity check is enabled for the pair (see + /// {setBlockNumberCheck}), a report whose block number is older than the last accepted one + /// is skipped — `StaleReportSkipped` is emitted and the report is consumed without executing + /// the target call or reverting. + /// Gas-guard: when `s_consumerGasLimit[target][selector]` is non-zero, the function + /// reverts with `InsufficientGas` before the target call if available gas is below + /// `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. The `gasLimit / 63` term accounts for + /// the EIP-150 (63/64) rule: a CALL forwards at most 63/64 of available gas, so + /// without this buffer a high gas limit (above ~441,000) would cause the target to + /// receive less than configured. This ensures a low-gas delivery is recorded as failed + /// by the forwarder and can be retried, preventing griefing attacks. Each + /// (target, selector) pair has its own configurable limit. + /// Pause guard: when the contract is paused (see {pause}), this function short-circuits + /// before any decoding or execution, and its behavior depends on the mode the owner + /// selected at pause time. In retryable mode it reverts with `EnforcedPause` (the revert + /// propagates through `onReport`, so the forwarder records the transmission as failed and + /// it resumes after {unpause}). In non-retryable mode it emits `ReportSkippedWhilePaused` + /// and returns, consuming (dropping) the report so it is not redelivered. + function _processReport(bytes calldata report) internal override { + if (paused()) { + if (s_retryableWhilePaused) { + revert EnforcedPause(); + } + emit ReportSkippedWhilePaused(); + return; + } + // Read the inherited permission fields directly (warm SLOADs). ReceiverTemplate.onReport + // already loaded all four slots before dispatching here, so these reads cost ~100 gas + // each — far cheaper than a self-STATICCALL to the external getters. + if (s_forwarderAddress == address(0)) { + revert InvalidForwarderAddress(); + } + if (s_expectedWorkflowId == bytes32(0) && + (s_expectedAuthor == address(0) || s_expectedWorkflowName == bytes10(0))) { + revert WorkflowIdentityNotConfigured(); + } + + (address target, uint256 reportBlockNumber, bytes memory data) = + abi.decode(report, (address, uint256, bytes)); + + if (target == address(0)) { + revert InvalidTargetAddress(); + } + if (data.length < 4) { + revert MissingSelector(); + } + + // Read the leading 4-byte selector from the in-memory `data`. Safe: length >= 4 is + // checked above, and a 32-byte mload assigned to bytes4 keeps the high (first) 4 bytes. + bytes4 selector; + assembly { + selector := mload(add(data, 0x20)) + } + if (!s_callAllowed[target][selector]) { + revert CallNotAllowed(target, selector); + } + + // Opt-in staleness protection: reject reports older than the last accepted one for this pair. + // CLA-parity comparison (>=): a report at the same block is still accepted. The stored block + // is updated before the gas guard, but an InsufficientGas revert rolls it back so a retry at + // the same block stays valid. + if (s_blockNumberCheckEnabled[target][selector]) { + uint256 lastReportBlock = s_lastReportBlock[target][selector]; + if (reportBlockNumber < lastReportBlock) { + emit StaleReportSkipped(target, selector, reportBlockNumber, lastReportBlock); + return; + } + s_lastReportBlock[target][selector] = reportBlockNumber; + } + + uint256 consumerGasLimit = s_consumerGasLimit[target][selector]; + bool success; + bytes memory returnData; + if (consumerGasLimit > 0) { + // consumerGasLimit / 63 compensates for EIP-150: a CALL forwards at most + // 63/64 of available gas. Without this term, limits above ~441,000 + // (63 × GAS_OVERHEAD, ~441,000) would cause the target to receive less than requested. + uint256 required = consumerGasLimit + consumerGasLimit / 63 + GAS_OVERHEAD; + if (gasleft() < required) { + revert InsufficientGas(gasleft(), required); + } + (success, returnData) = target.call{gas: consumerGasLimit}(data); + } else { + (success, returnData) = target.call(data); + } + + if (success) { + emit CallExecuted(target, selector, returnData); + } else { + emit CallFailed(target, selector, returnData); + } } - } -} +} \ No newline at end of file diff --git a/contracts/src/v0.8/automation/IERC165.sol b/contracts/src/v0.8/automation/IERC165.sol new file mode 100644 index 0000000000..9af4bf800f --- /dev/null +++ b/contracts/src/v0.8/automation/IERC165.sol @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: MIT +pragma solidity >=0.6.2; + +interface IERC165 { + /// @notice Query if a contract implements an interface + /// @param interfaceID The interface identifier, as specified in ERC-165 + /// @dev Interface identification is specified in ERC-165. This function + /// uses less than 30,000 gas. + /// @return `true` if the contract implements `interfaceID` and + /// `interfaceID` is not 0xffffffff, `false` otherwise + function supportsInterface(bytes4 interfaceID) external view returns (bool); +} diff --git a/contracts/src/v0.8/automation/IReceiver.sol b/contracts/src/v0.8/automation/IReceiver.sol index b427f81f5b..8ead884408 100644 --- a/contracts/src/v0.8/automation/IReceiver.sol +++ b/contracts/src/v0.8/automation/IReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import {IERC165} from "../vendor/IERC165.sol"; +import {IERC165} from "./IERC165.sol"; /// @title IReceiver - receives keystone reports /// @notice Implementations must support the IReceiver interface through ERC165. @@ -11,5 +11,8 @@ interface IReceiver is IERC165 { /// limit. The receiver is responsible for discarding stale reports. /// @param metadata Report's metadata. /// @param report Workflow report. - function onReport(bytes calldata metadata, bytes calldata report) external; -} + function onReport( + bytes calldata metadata, + bytes calldata report + ) external; +} \ No newline at end of file diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index daa80420fe..57b792a3f4 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -1,23 +1,30 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.24; +pragma solidity ^0.8.0; -import {IERC165} from "../vendor/IERC165.sol"; +import {IERC165} from "./IERC165.sol"; import {IReceiver} from "./IReceiver.sol"; -import {Ownable} from "@openzeppelin/contracts@5.3.0/access/Ownable.sol"; +import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol"; /// @title ReceiverTemplate - Abstract receiver with optional permission controls /// @notice Provides flexible, updatable security checks for receiving workflow reports /// @dev The forwarder address is required at construction time for security. /// Additional permission fields can be configured using setter functions. abstract contract ReceiverTemplate is IReceiver, Ownable { - address private s_forwarderAddress; - - address private s_expectedAuthor; - bytes10 private s_expectedWorkflowName; - bytes32 private s_expectedWorkflowId; - + // Required permission field at deployment, configurable after. + // `internal` (not `private`) so concrete receivers can read it directly with a warm SLOAD + // instead of paying for a self-STATICCALL to the external getter. + address internal s_forwarderAddress; // If set, only this address can call onReport + + // Optional permission fields (all default to zero = disabled). + // `internal` for the same reason as s_forwarderAddress above. + address internal s_expectedAuthor; // If set, only reports from this workflow owner are accepted + bytes10 internal s_expectedWorkflowName; // Only validated when s_expectedAuthor is also set + bytes32 internal s_expectedWorkflowId; // If set, only reports from this specific workflow ID are accepted + + // Hex character lookup table for bytes-to-hex conversion bytes private constant HEX_CHARS = "0123456789abcdef"; + // Custom errors error InvalidForwarderAddress(); error InvalidSender(address sender, address expected); error InvalidAuthor(address received, address expected); @@ -25,42 +32,62 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { error InvalidWorkflowId(bytes32 received, bytes32 expected); error WorkflowNameRequiresAuthorValidation(); + // Events event ForwarderAddressUpdated(address indexed previousForwarder, address indexed newForwarder); event ExpectedAuthorUpdated(address indexed previousAuthor, address indexed newAuthor); event ExpectedWorkflowNameUpdated(bytes10 indexed previousName, bytes10 indexed newName); event ExpectedWorkflowIdUpdated(bytes32 indexed previousId, bytes32 indexed newId); event SecurityWarning(string message); + /// @notice Constructor sets msg.sender as the owner and configures the forwarder address + /// @param _forwarderAddress The address of the Chainlink Forwarder contract (cannot be address(0)) + /// @dev The forwarder address is required for security - it ensures only verified reports are processed constructor( address _forwarderAddress ) Ownable(msg.sender) { - if (_forwarderAddress == address(0)) revert InvalidForwarderAddress(); + if (_forwarderAddress == address(0)) { + revert InvalidForwarderAddress(); + } s_forwarderAddress = _forwarderAddress; emit ForwarderAddressUpdated(address(0), _forwarderAddress); } + /// @notice Returns the configured forwarder address + /// @return The forwarder address (address(0) if disabled) function getForwarderAddress() external view returns (address) { return s_forwarderAddress; } + /// @notice Returns the expected workflow author address + /// @return The expected author address (address(0) if not set) function getExpectedAuthor() external view returns (address) { return s_expectedAuthor; } + /// @notice Returns the expected workflow name + /// @return The expected workflow name (bytes10(0) if not set) function getExpectedWorkflowName() external view returns (bytes10) { return s_expectedWorkflowName; } + /// @notice Returns the expected workflow ID + /// @return The expected workflow ID (bytes32(0) if not set) function getExpectedWorkflowId() external view returns (bytes32) { return s_expectedWorkflowId; } /// @inheritdoc IReceiver - function onReport(bytes calldata metadata, bytes calldata report) external override { + /// @dev Performs optional validation checks based on which permission fields are set + function onReport( + bytes calldata metadata, + bytes calldata report + ) external override { + // Security Check 1: Verify caller is the trusted Chainlink Forwarder (if configured) if (s_forwarderAddress != address(0) && msg.sender != s_forwarderAddress) { revert InvalidSender(msg.sender, s_forwarderAddress); } + // Security Checks 2-4: Verify workflow identity - ID, owner, and/or name (if any are configured) if (s_expectedWorkflowId != bytes32(0) || s_expectedAuthor != address(0) || s_expectedWorkflowName != bytes10(0)) { (bytes32 workflowId, bytes10 workflowName, address workflowOwner) = _decodeMetadata(metadata); @@ -70,24 +97,52 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { if (s_expectedAuthor != address(0) && workflowOwner != s_expectedAuthor) { revert InvalidAuthor(workflowOwner, s_expectedAuthor); } + + // ================================================================ + // WORKFLOW NAME VALIDATION - REQUIRES AUTHOR VALIDATION + // ================================================================ + // Do not rely on workflow name validation alone. Workflow names are unique + // per owner, but not across owners. + // Furthermore, workflow names use 40-bit truncation (bytes10), making collisions possible. + // Therefore, workflow name validation REQUIRES author (workflow owner) validation. + // The code enforces this dependency at runtime. + // ================================================================ if (s_expectedWorkflowName != bytes10(0)) { - if (s_expectedAuthor == address(0)) revert WorkflowNameRequiresAuthorValidation(); - if (workflowName != s_expectedWorkflowName) revert InvalidWorkflowName(workflowName, s_expectedWorkflowName); + // Author must be configured if workflow name is used + if (s_expectedAuthor == address(0)) { + revert WorkflowNameRequiresAuthorValidation(); + } + // Validate workflow name matches (author already validated above) + if (workflowName != s_expectedWorkflowName) { + revert InvalidWorkflowName(workflowName, s_expectedWorkflowName); + } } } _processReport(report); } + /// @notice Updates the forwarder address that is allowed to call onReport + /// @param _forwarder The new forwarder address + /// @dev WARNING: Setting to address(0) disables forwarder validation. + /// This makes your contract INSECURE - anyone can call onReport() with arbitrary data. + /// Only use address(0) if you fully understand the security implications. function setForwarderAddress( address _forwarder ) external onlyOwner { address previousForwarder = s_forwarderAddress; - if (_forwarder == address(0)) emit SecurityWarning("Forwarder address set to zero - contract is now INSECURE"); + + // Emit warning if disabling forwarder check + if (_forwarder == address(0)) { + emit SecurityWarning("Forwarder address set to zero - contract is now INSECURE"); + } + s_forwarderAddress = _forwarder; emit ForwarderAddressUpdated(previousForwarder, _forwarder); } + /// @notice Updates the expected workflow owner address + /// @param _author The new expected author address (use address(0) to disable this check) function setExpectedAuthor( address _author ) external onlyOwner { @@ -96,15 +151,27 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { emit ExpectedAuthorUpdated(previousAuthor, _author); } + /// @notice Updates the expected workflow name from a plaintext string + /// @param _name The workflow name as a string (use empty string "" to disable this check) + /// @dev IMPORTANT: Workflow name validation REQUIRES author validation to be enabled. + /// The workflow name uses only 40-bit truncation, making collision attacks feasible + /// when used alone. However, since workflow names are unique per owner, validating + /// both the name AND the author address provides adequate security. + /// You must call setExpectedAuthor() before or after calling this function. + /// The name is hashed using SHA256 and truncated to bytes10. function setExpectedWorkflowName( string calldata _name ) external onlyOwner { bytes10 previousName = s_expectedWorkflowName; + if (bytes(_name).length == 0) { s_expectedWorkflowName = bytes10(0); emit ExpectedWorkflowNameUpdated(previousName, bytes10(0)); return; } + + // Convert workflow name to bytes10: + // SHA256 hash → hex encode → take first 10 chars → hex encode those chars bytes32 hash = sha256(bytes(_name)); bytes memory hexString = _bytesToHexString(abi.encodePacked(hash)); bytes memory first10 = new bytes(10); @@ -115,6 +182,8 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { emit ExpectedWorkflowNameUpdated(previousName, s_expectedWorkflowName); } + /// @notice Updates the expected workflow ID + /// @param _id The new expected workflow ID (use bytes32(0) to disable this check) function setExpectedWorkflowId( bytes32 _id ) external onlyOwner { @@ -123,20 +192,35 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { emit ExpectedWorkflowIdUpdated(previousId, _id); } + /// @notice Helper function to convert bytes to hex string + /// @param data The bytes to convert + /// @return The hex string representation function _bytesToHexString( bytes memory data ) private pure returns (bytes memory) { bytes memory hexString = new bytes(data.length * 2); + for (uint256 i = 0; i < data.length; i++) { hexString[i * 2] = HEX_CHARS[uint8(data[i] >> 4)]; hexString[i * 2 + 1] = HEX_CHARS[uint8(data[i] & 0x0f)]; } + return hexString; } + /// @notice Extracts all metadata fields from the onReport metadata parameter + /// @param metadata The metadata bytes encoded using abi.encodePacked(workflowId, workflowName, workflowOwner) + /// @return workflowId The unique identifier of the workflow (bytes32) + /// @return workflowName The name of the workflow (bytes10) + /// @return workflowOwner The owner address of the workflow function _decodeMetadata( bytes memory metadata ) internal pure returns (bytes32 workflowId, bytes10 workflowName, address workflowOwner) { + // Metadata structure (encoded using abi.encodePacked by the Forwarder): + // - First 32 bytes: length of the byte array (standard for dynamic bytes) + // - Offset 32, size 32: workflow_id (bytes32) + // - Offset 64, size 10: workflow_name (bytes10) + // - Offset 74, size 20: workflow_owner (address) assembly { workflowId := mload(add(metadata, 32)) workflowName := mload(add(metadata, 64)) @@ -145,6 +229,9 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { return (workflowId, workflowName, workflowOwner); } + /// @notice Abstract function to process the report data + /// @param report The report calldata containing your workflow's encoded data + /// @dev Implement this function with your contract's business logic function _processReport( bytes calldata report ) internal virtual; @@ -155,4 +242,4 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { ) public view virtual override returns (bool) { return interfaceId == type(IReceiver).interfaceId || interfaceId == type(IERC165).interfaceId; } -} +} \ No newline at end of file diff --git a/gethwrappers/generated/automation_receiver/automation_receiver.go b/gethwrappers/generated/automation_receiver/automation_receiver.go index 64f94b0f4e..b67d4a04b8 100644 --- a/gethwrappers/generated/automation_receiver/automation_receiver.go +++ b/gethwrappers/generated/automation_receiver/automation_receiver.go @@ -31,8 +31,8 @@ var ( ) var AutomationReceiverMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"typeAndVersion\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"string\",\"internalType\":\"string\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", - Bin: "0x608060405234801562000010575f80fd5b506040516200198a3803806200198a83398101604081905262000033916200012c565b8033806200005a57604051631e4fbdf760e01b81525f600482015260240160405180910390fd5b6200006581620000dd565b506001600160a01b0381166200008d5760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040515f907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a350506200015b565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f602082840312156200013d575f80fd5b81516001600160a01b038116811462000154575f80fd5b9392505050565b61182180620001695f395ff3fe608060405234801561000f575f80fd5b50600436106100fb575f3560e01c80639c1c77ca11610093578063d60c884b11610063578063d60c884b146102f8578063d777cc6d1461030b578063f2fde38b1461031e578063f5c793ef14610331575f80fd5b80639c1c77ca14610270578063a619d81814610283578063bc1fc27a146102d2578063c3c44ac2146102e5575f80fd5b8063715018a6116100ce578063715018a6146101cd578063797c8d69146101d7578063805f2132146102405780638da5cb5b14610253575f80fd5b806301ffc9a7146100ff578063181f5a77146101275780633397cf67146101705780633441856f146101af575b5f80fd5b61011261010d36600461139f565b610342565b60405190151581526020015b60405180910390f35b6101636040518060400160405280601881526020017f4175746f6d6174696f6e526563656976657220312e302e30000000000000000081525081565b60405161011e919061142a565b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161011e565b60015473ffffffffffffffffffffffffffffffffffffffff1661018a565b6101d56103da565b005b6101126101e536600461145d565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526004602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101d561024e3660046114d5565b6103ed565b5f5473ffffffffffffffffffffffffffffffffffffffff1661018a565b6101d561027e36600461153c565b6107ac565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff00000000000000000000000000000000000000000000909116815260200161011e565b6101d56102e0366004611586565b6108ba565b6101d56102f33660046115c5565b610b28565b6101d56103063660046115dc565b610b68565b6101d56103193660046115dc565b610be6565b6101d561032c3660046115dc565b610d13565b60035460405190815260200161011e565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f805f21320000000000000000000000000000000000000000000000000000000014806103d457507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b6103e2610d76565b6103eb5f610dc8565b565b60015473ffffffffffffffffffffffffffffffffffffffff161580159061042c575060015473ffffffffffffffffffffffffffffffffffffffff163314155b1561048a576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b6003541515806104b1575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806104fa575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b1561079c575f805f61054087878080601f0160208091040260200160405190810160405280939291908181526020018383808284375f92019190915250610e3c92505050565b60035492955090935091501580159061055b57506003548314155b156105a0576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610481918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff16158015906105e2575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b1561063d576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610481565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016156107985760025473ffffffffffffffffffffffffffffffffffffffff166106d1576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610798576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610481565b5050505b6107a68282610e55565b50505050565b6107b4610d76565b73ffffffffffffffffffffffffffffffffffffffff8316610801576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83165f8181526004602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b6108c2610d76565b60025474010000000000000000000000000000000000000000900460b01b5f82900361096357600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040515f907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b5f600284846040516109769291906115f7565b602060405180830381855afa158015610991573d5f803e3d5ffd5b5050506040513d601f19601f820116820180604052508101906109b49190611606565b90505f6109e1826040516020016109cd91815260200190565b60405160208183030381529060405261111c565b60408051600a8082528183019092529192505f91906020820181803683370190505090505f5b600a811015610a7557828181518110610a2257610a2261164a565b602001015160f81c60f81b828281518110610a3f57610a3f61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101610a07565b50610a7f81611677565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5905f90a3505050505050565b610b30610d76565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03905f90a35050565b610b70610d76565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31905f90a35050565b610bee610d76565b60015473ffffffffffffffffffffffffffffffffffffffff908116908216610c9e577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7604051610c959060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e905f90a35050565b610d1b610d76565b73ffffffffffffffffffffffffffffffffffffffff8116610d6a576040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081525f6004820152602401610481565b610d7381610dc8565b50565b5f5473ffffffffffffffffffffffffffffffffffffffff1633146103eb576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610481565b5f805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b5f80610e63838501856116c6565b909250905073ffffffffffffffffffffffffffffffffffffffff8216610eb5576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015610ef1576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff84165f9081526004835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff16610fc1576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610481565b5f808473ffffffffffffffffffffffffffffffffffffffff1684604051610fe891906117a2565b5f604051808303815f865af19150503d805f8114611021576040519150601f19603f3d011682016040523d82523d5f602084013e611026565b606091505b509150915081156110a457827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb88483604051611097919061142a565b60405180910390a3611113565b827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168573ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b68360405161110a919061142a565b60405180910390a35b50505050505050565b60605f8251600261112d91906117ea565b67ffffffffffffffff8111156111455761114561161d565b6040519080825280601f01601f19166020018201604052801561116f576020820181803683370190505b5090505f5b8351811015611364576040518060400160405280601081526020017f303132333435363738396162636465660000000000000000000000000000000081525060048583815181106111c7576111c761164a565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c9081106112075761120761164a565b01602001517fff00000000000000000000000000000000000000000000000000000000000000168261123a8360026117ea565b8151811061124a5761124a61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053506040518060400160405280601081526020017f30313233343536373839616263646566000000000000000000000000000000008152508482815181106112c0576112c061164a565b602091010151815160f89190911c600f169081106112e0576112e061164a565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016826113138360026117ea565b61131e906001611801565b8151811061132e5761132e61164a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101611174565b5092915050565b80357fffffffff000000000000000000000000000000000000000000000000000000008116811461139a575f80fd5b919050565b5f602082840312156113af575f80fd5b6113b88261136b565b9392505050565b5f5b838110156113d95781810151838201526020016113c1565b50505f910152565b5f81518084526113f88160208601602086016113bf565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081525f6113b860208301846113e1565b73ffffffffffffffffffffffffffffffffffffffff81168114610d73575f80fd5b5f806040838503121561146e575f80fd5b82356114798161143c565b91506114876020840161136b565b90509250929050565b5f8083601f8401126114a0575f80fd5b50813567ffffffffffffffff8111156114b7575f80fd5b6020830191508360208285010111156114ce575f80fd5b9250929050565b5f805f80604085870312156114e8575f80fd5b843567ffffffffffffffff808211156114ff575f80fd5b61150b88838901611490565b90965094506020870135915080821115611523575f80fd5b5061153087828801611490565b95989497509550505050565b5f805f6060848603121561154e575f80fd5b83356115598161143c565b92506115676020850161136b565b91506040840135801515811461157b575f80fd5b809150509250925092565b5f8060208385031215611597575f80fd5b823567ffffffffffffffff8111156115ad575f80fd5b6115b985828601611490565b90969095509350505050565b5f602082840312156115d5575f80fd5b5035919050565b5f602082840312156115ec575f80fd5b81356113b88161143c565b818382375f9101908152919050565b5f60208284031215611616575f80fd5b5051919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f815160208301517fffffffffffffffffffff000000000000000000000000000000000000000000008082169350600a8310156116be57808184600a0360031b1b83161693505b505050919050565b5f80604083850312156116d7575f80fd5b82356116e28161143c565b9150602083013567ffffffffffffffff808211156116fe575f80fd5b818501915085601f830112611711575f80fd5b8135818111156117235761172361161d565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156117695761176961161d565b81604052828152886020848701011115611781575f80fd5b826020860160208301375f6020848301015280955050505050509250929050565b5f82516117b38184602087016113bf565b9190910192915050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b80820281158282048414176103d4576103d46117bd565b808201808211156103d4576103d46117bd56fea164736f6c6343000818000a", + ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getBlockNumberCheck\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"enabled\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"lastReportBlock\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getConsumerGasLimit\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pause\",\"inputs\":[{\"name\":\"retryable\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"retryableWhilePaused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setBlockNumberCheck\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"enabled\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"initialBlockNumber\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setConsumerGasLimit\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"gasLimit\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"unpause\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"BlockNumberCheckSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"enabled\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"initialBlockNumber\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ConsumerGasLimitSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"previousLimit\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"newLimit\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Paused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ReportSkippedWhilePaused\",\"inputs\":[],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"StaleReportSkipped\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reportBlockNumber\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"lastReportBlock\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Unpaused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"EnforcedPause\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"ExpectedPause\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InsufficientGas\",\"inputs\":[{\"name\":\"available\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"required\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"TargetHasNoCode\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"WorkflowIdentityNotConfigured\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", + Bin: "0x608060405234801561000f575f80fd5b506040516124d03803806124d083398101604081905261002e9161012c565b80338061005457604051631e4fbdf760e01b81525f600482015260240160405180910390fd5b61005d816100dd565b506001600160a01b0381166100845760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040515f907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a350506004805460ff19169055610159565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f6020828403121561013c575f80fd5b81516001600160a01b0381168114610152575f80fd5b9392505050565b61236a806101665f395ff3fe608060405234801561000f575f80fd5b5060043610610184575f3560e01c80638da5cb5b116100dd578063c3c44ac211610088578063d8fb859411610063578063d8fb859414610429578063f2fde38b14610453578063f5c793ef14610466575f80fd5b8063c3c44ac2146103f0578063d60c884b14610403578063d777cc6d14610416575f80fd5b8063b25de11e116100b8578063b25de11e146103bf578063bc1fc27a146103ca578063c2f7510d146103dd575f80fd5b80638da5cb5b146103405780639c1c77ca1461035d578063a619d81814610370575f80fd5b80635c975abb1161013d578063797c8d6911610118578063797c8d6914610250578063805f2132146102b9578063851ca9c1146102cc575f80fd5b80635c975abb1461022a578063715018a61461023557806375483caf1461023d575f80fd5b80633397cf671161016d5780633397cf67146101c55780633441856f146102045780633f4ba83a14610222575f80fd5b806301ffc9a71461018857806302329a29146101b0575b5f80fd5b61019b610196366004611def565b61046e565b60405190151581526020015b60405180910390f35b6101c36101be366004611e1e565b610506565b005b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101a7565b60015473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c3610545565b60045460ff1661019b565b6101c3610557565b6101c361024b366004611e58565b610568565b61019b61025e366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526005602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101c36102c7366004611f13565b6106ec565b6103326102da366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526006602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205492915050565b6040519081526020016101a7565b5f5473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c361036b366004611f7f565b610aab565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff0000000000000000000000000000000000000000000090911681526020016101a7565b60095460ff1661019b565b6101c36103d8366004611fc1565b610c2a565b6101c36103eb366004612000565b610e98565b6101c36103fe36600461203c565b610f85565b6101c3610411366004612053565b610fc5565b6101c3610424366004612053565b611043565b61043c610437366004611ea2565b611170565b6040805192151583526020830191909152016101a7565b6101c3610461366004612053565b6111e5565b600354610332565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f805f213200000000000000000000000000000000000000000000000000000000148061050057507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b61050e611245565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016821515179055610542611297565b50565b61054d611245565b61055561131c565b565b61055f611245565b6105555f611373565b610570611245565b73ffffffffffffffffffffffffffffffffffffffff84166105bd576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168452909152812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001684151517905582610643575f610651565b811561064f5781610651565b435b73ffffffffffffffffffffffffffffffffffffffff86165f8181526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008a16808552908352928190208590558051881515815291820185905293945090927ff19a6052943cc4c32e1644d475a7b4e6f517bcae63159220028f5de68d6d0364910160405180910390a35050505050565b60015473ffffffffffffffffffffffffffffffffffffffff161580159061072b575060015473ffffffffffffffffffffffffffffffffffffffff163314155b15610789576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b6003541515806107b0575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806107f9575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b15610a9b575f805f61083f87878080601f0160208091040260200160405190810160405280939291908181526020018383808284375f920191909152506113e792505050565b60035492955090935091501580159061085a57506003548314155b1561089f576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610780918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff16158015906108e1575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b1561093c576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610780565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615610a975760025473ffffffffffffffffffffffffffffffffffffffff166109d0576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610a97576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610780565b5050505b610aa58282611400565b50505050565b610ab3611245565b73ffffffffffffffffffffffffffffffffffffffff8316610b00576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b808015610b22575073ffffffffffffffffffffffffffffffffffffffff83163b155b15610b71576040517ffff2336100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84166004820152602401610780565b73ffffffffffffffffffffffffffffffffffffffff83165f8181526005602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b610c32611245565b60025474010000000000000000000000000000000000000000900460b01b5f829003610cd357600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040515f907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b5f60028484604051610ce692919061206e565b602060405180830381855afa158015610d01573d5f803e3d5ffd5b5050506040513d601f19601f82011682018060405250810190610d24919061207d565b90505f610d5182604051602001610d3d91815260200190565b604051602081830303815290604052611af3565b60408051600a8082528183019092529192505f91906020820181803683370190505090505f5b600a811015610de557828181518110610d9257610d926120c1565b602001015160f81c60f81b828281518110610daf57610daf6120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101610d77565b50610def816120ee565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5905f90a3505050505050565b610ea0611245565b73ffffffffffffffffffffffffffffffffffffffff8316610eed576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83165f8181526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000871680855290835292819020805490869055815181815292830186905293917ff3f16b36d6fb2a97e5e66d28e758a4d457e80197e1d455f692a96be32091fa3a910160405180910390a350505050565b610f8d611245565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03905f90a35050565b610fcd611245565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31905f90a35050565b61104b611245565b60015473ffffffffffffffffffffffffffffffffffffffff9081169082166110fb577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf76040516110f29060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e905f90a35050565b73ffffffffffffffffffffffffffffffffffffffff82165f8181526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008616808552908352818420549484526008835281842090845290915290205460ff909116905b9250929050565b6111ed611245565b73ffffffffffffffffffffffffffffffffffffffff811661123c576040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081525f6004820152602401610780565b61054281611373565b5f5473ffffffffffffffffffffffffffffffffffffffff163314610555576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610780565b61129f611d42565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586112f23390565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b611324611d7f565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa336112f2565b5f805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b60045460ff16156114745760095460ff1615611448576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517ff37c389ae9f5e13dbbef9f62b1ad0893e89c865ee834b2e221d11ebcf3cacd51905f90a15050565b60015473ffffffffffffffffffffffffffffffffffffffff166114c3576040517f381dd54000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600354158015611530575060025473ffffffffffffffffffffffffffffffffffffffff161580611530575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016155b15611567576040517f8ec26f9a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f80806115768486018661215a565b9194509250905073ffffffffffffffffffffffffffffffffffffffff83166115ca576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015611606576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff85165f9081526005835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff166116d6576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff851660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610780565b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff161561185e5773ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000085168452909152902054808410156118085760408051858152602081018390527fffffffff0000000000000000000000000000000000000000000000000000000084169173ffffffffffffffffffffffffffffffffffffffff8816917f96e22437f0b9d1dfe909221668f6ad9813c1128b60a7b4b3dee74e4248df834a910160405180910390a350505050505050565b5073ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290208390555b73ffffffffffffffffffffffffffffffffffffffff84165f9081526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000851684529091528120549060608215611996575f611b586118c8603f86612292565b6118d290866122ca565b6118dc91906122ca565b9050805a1015611924575a6040517f23e228cb000000000000000000000000000000000000000000000000000000008152600481019190915260248101829052604401610780565b8773ffffffffffffffffffffffffffffffffffffffff16848760405161194a91906122dd565b5f604051808303815f8787f1925050503d805f8114611984576040519150601f19603f3d011682016040523d82523d5f602084013e611989565b606091505b509093509150611a009050565b8673ffffffffffffffffffffffffffffffffffffffff16856040516119bb91906122dd565b5f604051808303815f865af19150503d805f81146119f4576040519150601f19603f3d011682016040523d82523d5f602084013e6119f9565b606091505b5090925090505b8115611a7957837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb88483604051611a6c91906122f3565b60405180910390a3611ae8565b837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b683604051611adf91906122f3565b60405180910390a35b505050505050505050565b60605f82516002611b049190612346565b67ffffffffffffffff811115611b1c57611b1c612094565b6040519080825280601f01601f191660200182016040528015611b46576020820181803683370190505b5090505f5b8351811015611d3b576040518060400160405280601081526020017f30313233343536373839616263646566000000000000000000000000000000008152506004858381518110611b9e57611b9e6120c1565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c908110611bde57611bde6120c1565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611c11836002612346565b81518110611c2157611c216120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053506040518060400160405280601081526020017f3031323334353637383961626364656600000000000000000000000000000000815250848281518110611c9757611c976120c1565b602091010151815160f89190911c600f16908110611cb757611cb76120c1565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611cea836002612346565b611cf59060016122ca565b81518110611d0557611d056120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101611b4b565b5092915050565b60045460ff1615610555576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60045460ff16610555576040517f8dfc202b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80357fffffffff0000000000000000000000000000000000000000000000000000000081168114611dea575f80fd5b919050565b5f60208284031215611dff575f80fd5b611e0882611dbb565b9392505050565b80358015158114611dea575f80fd5b5f60208284031215611e2e575f80fd5b611e0882611e0f565b73ffffffffffffffffffffffffffffffffffffffff81168114610542575f80fd5b5f805f8060808587031215611e6b575f80fd5b8435611e7681611e37565b9350611e8460208601611dbb565b9250611e9260408601611e0f565b9396929550929360600135925050565b5f8060408385031215611eb3575f80fd5b8235611ebe81611e37565b9150611ecc60208401611dbb565b90509250929050565b5f8083601f840112611ee5575f80fd5b50813567ffffffffffffffff811115611efc575f80fd5b6020830191508360208285010111156111de575f80fd5b5f805f8060408587031215611f26575f80fd5b843567ffffffffffffffff811115611f3c575f80fd5b611f4887828801611ed5565b909550935050602085013567ffffffffffffffff811115611f67575f80fd5b611f7387828801611ed5565b95989497509550505050565b5f805f60608486031215611f91575f80fd5b8335611f9c81611e37565b9250611faa60208501611dbb565b9150611fb860408501611e0f565b90509250925092565b5f8060208385031215611fd2575f80fd5b823567ffffffffffffffff811115611fe8575f80fd5b611ff485828601611ed5565b90969095509350505050565b5f805f60608486031215612012575f80fd5b833561201d81611e37565b925061202b60208501611dbb565b929592945050506040919091013590565b5f6020828403121561204c575f80fd5b5035919050565b5f60208284031215612063575f80fd5b8135611e0881611e37565b818382375f9101908152919050565b5f6020828403121561208d575f80fd5b5051919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b805160208201517fffffffffffffffffffff0000000000000000000000000000000000000000000081169190600a821015612153577fffffffffffffffffffff000000000000000000000000000000000000000000008083600a0360031b1b82161692505b5050919050565b5f805f6060848603121561216c575f80fd5b833561217781611e37565b925060208401359150604084013567ffffffffffffffff811115612199575f80fd5b8401601f810186136121a9575f80fd5b803567ffffffffffffffff8111156121c3576121c3612094565b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8501160116810181811067ffffffffffffffff8211171561222f5761222f612094565b604052818152828201602001881015612246575f80fd5b816020840160208301375f602083830101528093505050509250925092565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f826122c5577f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b500490565b8082018082111561050057610500612265565b5f82518060208501845e5f920191825250919050565b602081525f82518060208401528060208501604085015e5f6040828501015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011684010191505092915050565b80820281158282048414176105005761050061226556fea164736f6c634300081a000a", } var AutomationReceiverABI = AutomationReceiverMetaData.ABI @@ -171,6 +171,58 @@ func (_AutomationReceiver *AutomationReceiverTransactorRaw) Transact(opts *bind. return _AutomationReceiver.Contract.contract.Transact(opts, method, params...) } +func (_AutomationReceiver *AutomationReceiverCaller) GetBlockNumberCheck(opts *bind.CallOpts, target common.Address, selector [4]byte) (GetBlockNumberCheck, + + error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getBlockNumberCheck", target, selector) + + outstruct := new(GetBlockNumberCheck) + if err != nil { + return *outstruct, err + } + + outstruct.Enabled = *abi.ConvertType(out[0], new(bool)).(*bool) + outstruct.LastReportBlock = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetBlockNumberCheck(target common.Address, selector [4]byte) (GetBlockNumberCheck, + + error) { + return _AutomationReceiver.Contract.GetBlockNumberCheck(&_AutomationReceiver.CallOpts, target, selector) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetBlockNumberCheck(target common.Address, selector [4]byte) (GetBlockNumberCheck, + + error) { + return _AutomationReceiver.Contract.GetBlockNumberCheck(&_AutomationReceiver.CallOpts, target, selector) +} + +func (_AutomationReceiver *AutomationReceiverCaller) GetConsumerGasLimit(opts *bind.CallOpts, target common.Address, selector [4]byte) (*big.Int, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "getConsumerGasLimit", target, selector) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_AutomationReceiver *AutomationReceiverSession) GetConsumerGasLimit(target common.Address, selector [4]byte) (*big.Int, error) { + return _AutomationReceiver.Contract.GetConsumerGasLimit(&_AutomationReceiver.CallOpts, target, selector) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) GetConsumerGasLimit(target common.Address, selector [4]byte) (*big.Int, error) { + return _AutomationReceiver.Contract.GetConsumerGasLimit(&_AutomationReceiver.CallOpts, target, selector) +} + func (_AutomationReceiver *AutomationReceiverCaller) GetExpectedAuthor(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _AutomationReceiver.contract.Call(opts, &out, "getExpectedAuthor") @@ -303,9 +355,9 @@ func (_AutomationReceiver *AutomationReceiverCallerSession) Owner() (common.Addr return _AutomationReceiver.Contract.Owner(&_AutomationReceiver.CallOpts) } -func (_AutomationReceiver *AutomationReceiverCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { +func (_AutomationReceiver *AutomationReceiverCaller) Paused(opts *bind.CallOpts) (bool, error) { var out []interface{} - err := _AutomationReceiver.contract.Call(opts, &out, "supportsInterface", interfaceId) + err := _AutomationReceiver.contract.Call(opts, &out, "paused") if err != nil { return *new(bool), err @@ -317,34 +369,56 @@ func (_AutomationReceiver *AutomationReceiverCaller) SupportsInterface(opts *bin } -func (_AutomationReceiver *AutomationReceiverSession) SupportsInterface(interfaceId [4]byte) (bool, error) { - return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) +func (_AutomationReceiver *AutomationReceiverSession) Paused() (bool, error) { + return _AutomationReceiver.Contract.Paused(&_AutomationReceiver.CallOpts) } -func (_AutomationReceiver *AutomationReceiverCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { - return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) +func (_AutomationReceiver *AutomationReceiverCallerSession) Paused() (bool, error) { + return _AutomationReceiver.Contract.Paused(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) RetryableWhilePaused(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _AutomationReceiver.contract.Call(opts, &out, "retryableWhilePaused") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + } -func (_AutomationReceiver *AutomationReceiverCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { +func (_AutomationReceiver *AutomationReceiverSession) RetryableWhilePaused() (bool, error) { + return _AutomationReceiver.Contract.RetryableWhilePaused(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCallerSession) RetryableWhilePaused() (bool, error) { + return _AutomationReceiver.Contract.RetryableWhilePaused(&_AutomationReceiver.CallOpts) +} + +func (_AutomationReceiver *AutomationReceiverCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { var out []interface{} - err := _AutomationReceiver.contract.Call(opts, &out, "typeAndVersion") + err := _AutomationReceiver.contract.Call(opts, &out, "supportsInterface", interfaceId) if err != nil { - return *new(string), err + return *new(bool), err } - out0 := *abi.ConvertType(out[0], new(string)).(*string) + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) return out0, err } -func (_AutomationReceiver *AutomationReceiverSession) TypeAndVersion() (string, error) { - return _AutomationReceiver.Contract.TypeAndVersion(&_AutomationReceiver.CallOpts) +func (_AutomationReceiver *AutomationReceiverSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) } -func (_AutomationReceiver *AutomationReceiverCallerSession) TypeAndVersion() (string, error) { - return _AutomationReceiver.Contract.TypeAndVersion(&_AutomationReceiver.CallOpts) +func (_AutomationReceiver *AutomationReceiverCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _AutomationReceiver.Contract.SupportsInterface(&_AutomationReceiver.CallOpts, interfaceId) } func (_AutomationReceiver *AutomationReceiverTransactor) OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) { @@ -359,6 +433,18 @@ func (_AutomationReceiver *AutomationReceiverTransactorSession) OnReport(metadat return _AutomationReceiver.Contract.OnReport(&_AutomationReceiver.TransactOpts, metadata, report) } +func (_AutomationReceiver *AutomationReceiverTransactor) Pause(opts *bind.TransactOpts, retryable bool) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "pause", retryable) +} + +func (_AutomationReceiver *AutomationReceiverSession) Pause(retryable bool) (*types.Transaction, error) { + return _AutomationReceiver.Contract.Pause(&_AutomationReceiver.TransactOpts, retryable) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) Pause(retryable bool) (*types.Transaction, error) { + return _AutomationReceiver.Contract.Pause(&_AutomationReceiver.TransactOpts, retryable) +} + func (_AutomationReceiver *AutomationReceiverTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { return _AutomationReceiver.contract.Transact(opts, "renounceOwnership") } @@ -371,6 +457,18 @@ func (_AutomationReceiver *AutomationReceiverTransactorSession) RenounceOwnershi return _AutomationReceiver.Contract.RenounceOwnership(&_AutomationReceiver.TransactOpts) } +func (_AutomationReceiver *AutomationReceiverTransactor) SetBlockNumberCheck(opts *bind.TransactOpts, target common.Address, selector [4]byte, enabled bool, initialBlockNumber *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setBlockNumberCheck", target, selector, enabled, initialBlockNumber) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetBlockNumberCheck(target common.Address, selector [4]byte, enabled bool, initialBlockNumber *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetBlockNumberCheck(&_AutomationReceiver.TransactOpts, target, selector, enabled, initialBlockNumber) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetBlockNumberCheck(target common.Address, selector [4]byte, enabled bool, initialBlockNumber *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetBlockNumberCheck(&_AutomationReceiver.TransactOpts, target, selector, enabled, initialBlockNumber) +} + func (_AutomationReceiver *AutomationReceiverTransactor) SetCallAllowed(opts *bind.TransactOpts, target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) { return _AutomationReceiver.contract.Transact(opts, "setCallAllowed", target, selector, allowed) } @@ -383,6 +481,18 @@ func (_AutomationReceiver *AutomationReceiverTransactorSession) SetCallAllowed(t return _AutomationReceiver.Contract.SetCallAllowed(&_AutomationReceiver.TransactOpts, target, selector, allowed) } +func (_AutomationReceiver *AutomationReceiverTransactor) SetConsumerGasLimit(opts *bind.TransactOpts, target common.Address, selector [4]byte, gasLimit *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "setConsumerGasLimit", target, selector, gasLimit) +} + +func (_AutomationReceiver *AutomationReceiverSession) SetConsumerGasLimit(target common.Address, selector [4]byte, gasLimit *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetConsumerGasLimit(&_AutomationReceiver.TransactOpts, target, selector, gasLimit) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) SetConsumerGasLimit(target common.Address, selector [4]byte, gasLimit *big.Int) (*types.Transaction, error) { + return _AutomationReceiver.Contract.SetConsumerGasLimit(&_AutomationReceiver.TransactOpts, target, selector, gasLimit) +} + func (_AutomationReceiver *AutomationReceiverTransactor) SetExpectedAuthor(opts *bind.TransactOpts, _author common.Address) (*types.Transaction, error) { return _AutomationReceiver.contract.Transact(opts, "setExpectedAuthor", _author) } @@ -443,6 +553,156 @@ func (_AutomationReceiver *AutomationReceiverTransactorSession) TransferOwnershi return _AutomationReceiver.Contract.TransferOwnership(&_AutomationReceiver.TransactOpts, newOwner) } +func (_AutomationReceiver *AutomationReceiverTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationReceiver.contract.Transact(opts, "unpause") +} + +func (_AutomationReceiver *AutomationReceiverSession) Unpause() (*types.Transaction, error) { + return _AutomationReceiver.Contract.Unpause(&_AutomationReceiver.TransactOpts) +} + +func (_AutomationReceiver *AutomationReceiverTransactorSession) Unpause() (*types.Transaction, error) { + return _AutomationReceiver.Contract.Unpause(&_AutomationReceiver.TransactOpts) +} + +type AutomationReceiverBlockNumberCheckSetIterator struct { + Event *AutomationReceiverBlockNumberCheckSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverBlockNumberCheckSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverBlockNumberCheckSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverBlockNumberCheckSet) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverBlockNumberCheckSetIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverBlockNumberCheckSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverBlockNumberCheckSet struct { + Target common.Address + Selector [4]byte + Enabled bool + InitialBlockNumber *big.Int + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterBlockNumberCheckSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverBlockNumberCheckSetIterator, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "BlockNumberCheckSet", targetRule, selectorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverBlockNumberCheckSetIterator{contract: _AutomationReceiver.contract, event: "BlockNumberCheckSet", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchBlockNumberCheckSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverBlockNumberCheckSet, target []common.Address, selector [][4]byte) (event.Subscription, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "BlockNumberCheckSet", targetRule, selectorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverBlockNumberCheckSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "BlockNumberCheckSet", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseBlockNumberCheckSet(log types.Log) (*AutomationReceiverBlockNumberCheckSet, error) { + event := new(AutomationReceiverBlockNumberCheckSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "BlockNumberCheckSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type AutomationReceiverCallAllowedSetIterator struct { Event *AutomationReceiverCallAllowedSet @@ -854,8 +1114,8 @@ func (_AutomationReceiver *AutomationReceiverFilterer) ParseCallFailed(log types return event, nil } -type AutomationReceiverExpectedAuthorUpdatedIterator struct { - Event *AutomationReceiverExpectedAuthorUpdated +type AutomationReceiverConsumerGasLimitSetIterator struct { + Event *AutomationReceiverConsumerGasLimitSet contract *bind.BoundContract event string @@ -866,7 +1126,7 @@ type AutomationReceiverExpectedAuthorUpdatedIterator struct { fail error } -func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { +func (it *AutomationReceiverConsumerGasLimitSetIterator) Next() bool { if it.fail != nil { return false @@ -875,7 +1135,7 @@ func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(AutomationReceiverExpectedAuthorUpdated) + it.Event = new(AutomationReceiverConsumerGasLimitSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -890,7 +1150,7 @@ func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(AutomationReceiverExpectedAuthorUpdated) + it.Event = new(AutomationReceiverConsumerGasLimitSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -905,51 +1165,53 @@ func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { } } -func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Error() error { +func (it *AutomationReceiverConsumerGasLimitSetIterator) Error() error { return it.fail } -func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Close() error { +func (it *AutomationReceiverConsumerGasLimitSetIterator) Close() error { it.sub.Unsubscribe() return nil } -type AutomationReceiverExpectedAuthorUpdated struct { - PreviousAuthor common.Address - NewAuthor common.Address - Raw types.Log +type AutomationReceiverConsumerGasLimitSet struct { + Target common.Address + Selector [4]byte + PreviousLimit *big.Int + NewLimit *big.Int + Raw types.Log } -func (_AutomationReceiver *AutomationReceiverFilterer) FilterExpectedAuthorUpdated(opts *bind.FilterOpts, previousAuthor []common.Address, newAuthor []common.Address) (*AutomationReceiverExpectedAuthorUpdatedIterator, error) { +func (_AutomationReceiver *AutomationReceiverFilterer) FilterConsumerGasLimitSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverConsumerGasLimitSetIterator, error) { - var previousAuthorRule []interface{} - for _, previousAuthorItem := range previousAuthor { - previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) } - var newAuthorRule []interface{} - for _, newAuthorItem := range newAuthor { - newAuthorRule = append(newAuthorRule, newAuthorItem) + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) } - logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ConsumerGasLimitSet", targetRule, selectorRule) if err != nil { return nil, err } - return &AutomationReceiverExpectedAuthorUpdatedIterator{contract: _AutomationReceiver.contract, event: "ExpectedAuthorUpdated", logs: logs, sub: sub}, nil + return &AutomationReceiverConsumerGasLimitSetIterator{contract: _AutomationReceiver.contract, event: "ConsumerGasLimitSet", logs: logs, sub: sub}, nil } -func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedAuthorUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedAuthorUpdated, previousAuthor []common.Address, newAuthor []common.Address) (event.Subscription, error) { +func (_AutomationReceiver *AutomationReceiverFilterer) WatchConsumerGasLimitSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverConsumerGasLimitSet, target []common.Address, selector [][4]byte) (event.Subscription, error) { - var previousAuthorRule []interface{} - for _, previousAuthorItem := range previousAuthor { - previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) } - var newAuthorRule []interface{} - for _, newAuthorItem := range newAuthor { - newAuthorRule = append(newAuthorRule, newAuthorItem) + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) } - logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ConsumerGasLimitSet", targetRule, selectorRule) if err != nil { return nil, err } @@ -959,8 +1221,8 @@ func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedAuthorUpdate select { case log := <-logs: - event := new(AutomationReceiverExpectedAuthorUpdated) - if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { + event := new(AutomationReceiverConsumerGasLimitSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "ConsumerGasLimitSet", log); err != nil { return err } event.Raw = log @@ -981,17 +1243,17 @@ func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedAuthorUpdate }), nil } -func (_AutomationReceiver *AutomationReceiverFilterer) ParseExpectedAuthorUpdated(log types.Log) (*AutomationReceiverExpectedAuthorUpdated, error) { - event := new(AutomationReceiverExpectedAuthorUpdated) - if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { +func (_AutomationReceiver *AutomationReceiverFilterer) ParseConsumerGasLimitSet(log types.Log) (*AutomationReceiverConsumerGasLimitSet, error) { + event := new(AutomationReceiverConsumerGasLimitSet) + if err := _AutomationReceiver.contract.UnpackLog(event, "ConsumerGasLimitSet", log); err != nil { return nil, err } event.Raw = log return event, nil } -type AutomationReceiverExpectedWorkflowIdUpdatedIterator struct { - Event *AutomationReceiverExpectedWorkflowIdUpdated +type AutomationReceiverExpectedAuthorUpdatedIterator struct { + Event *AutomationReceiverExpectedAuthorUpdated contract *bind.BoundContract event string @@ -1002,7 +1264,7 @@ type AutomationReceiverExpectedWorkflowIdUpdatedIterator struct { fail error } -func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Next() bool { if it.fail != nil { return false @@ -1011,7 +1273,7 @@ func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + it.Event = new(AutomationReceiverExpectedAuthorUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1026,7 +1288,7 @@ func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + it.Event = new(AutomationReceiverExpectedAuthorUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1041,7 +1303,143 @@ func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { } } -func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Error() error { +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverExpectedAuthorUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverExpectedAuthorUpdated struct { + PreviousAuthor common.Address + NewAuthor common.Address + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterExpectedAuthorUpdated(opts *bind.FilterOpts, previousAuthor []common.Address, newAuthor []common.Address) (*AutomationReceiverExpectedAuthorUpdatedIterator, error) { + + var previousAuthorRule []interface{} + for _, previousAuthorItem := range previousAuthor { + previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + } + var newAuthorRule []interface{} + for _, newAuthorItem := range newAuthor { + newAuthorRule = append(newAuthorRule, newAuthorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverExpectedAuthorUpdatedIterator{contract: _AutomationReceiver.contract, event: "ExpectedAuthorUpdated", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchExpectedAuthorUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedAuthorUpdated, previousAuthor []common.Address, newAuthor []common.Address) (event.Subscription, error) { + + var previousAuthorRule []interface{} + for _, previousAuthorItem := range previousAuthor { + previousAuthorRule = append(previousAuthorRule, previousAuthorItem) + } + var newAuthorRule []interface{} + for _, newAuthorItem := range newAuthor { + newAuthorRule = append(newAuthorRule, newAuthorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ExpectedAuthorUpdated", previousAuthorRule, newAuthorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverExpectedAuthorUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseExpectedAuthorUpdated(log types.Log) (*AutomationReceiverExpectedAuthorUpdated, error) { + event := new(AutomationReceiverExpectedAuthorUpdated) + if err := _AutomationReceiver.contract.UnpackLog(event, "ExpectedAuthorUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverExpectedWorkflowIdUpdatedIterator struct { + Event *AutomationReceiverExpectedWorkflowIdUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverExpectedWorkflowIdUpdated) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverExpectedWorkflowIdUpdatedIterator) Error() error { return it.fail } @@ -1534,8 +1932,8 @@ func (_AutomationReceiver *AutomationReceiverFilterer) ParseOwnershipTransferred return event, nil } -type AutomationReceiverSecurityWarningIterator struct { - Event *AutomationReceiverSecurityWarning +type AutomationReceiverPausedIterator struct { + Event *AutomationReceiverPaused contract *bind.BoundContract event string @@ -1546,7 +1944,7 @@ type AutomationReceiverSecurityWarningIterator struct { fail error } -func (it *AutomationReceiverSecurityWarningIterator) Next() bool { +func (it *AutomationReceiverPausedIterator) Next() bool { if it.fail != nil { return false @@ -1555,7 +1953,7 @@ func (it *AutomationReceiverSecurityWarningIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(AutomationReceiverSecurityWarning) + it.Event = new(AutomationReceiverPaused) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1570,7 +1968,7 @@ func (it *AutomationReceiverSecurityWarningIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(AutomationReceiverSecurityWarning) + it.Event = new(AutomationReceiverPaused) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1585,32 +1983,32 @@ func (it *AutomationReceiverSecurityWarningIterator) Next() bool { } } -func (it *AutomationReceiverSecurityWarningIterator) Error() error { +func (it *AutomationReceiverPausedIterator) Error() error { return it.fail } -func (it *AutomationReceiverSecurityWarningIterator) Close() error { +func (it *AutomationReceiverPausedIterator) Close() error { it.sub.Unsubscribe() return nil } -type AutomationReceiverSecurityWarning struct { - Message string +type AutomationReceiverPaused struct { + Account common.Address Raw types.Log } -func (_AutomationReceiver *AutomationReceiverFilterer) FilterSecurityWarning(opts *bind.FilterOpts) (*AutomationReceiverSecurityWarningIterator, error) { +func (_AutomationReceiver *AutomationReceiverFilterer) FilterPaused(opts *bind.FilterOpts) (*AutomationReceiverPausedIterator, error) { - logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "SecurityWarning") + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "Paused") if err != nil { return nil, err } - return &AutomationReceiverSecurityWarningIterator{contract: _AutomationReceiver.contract, event: "SecurityWarning", logs: logs, sub: sub}, nil + return &AutomationReceiverPausedIterator{contract: _AutomationReceiver.contract, event: "Paused", logs: logs, sub: sub}, nil } -func (_AutomationReceiver *AutomationReceiverFilterer) WatchSecurityWarning(opts *bind.WatchOpts, sink chan<- *AutomationReceiverSecurityWarning) (event.Subscription, error) { +func (_AutomationReceiver *AutomationReceiverFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverPaused) (event.Subscription, error) { - logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "SecurityWarning") + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "Paused") if err != nil { return nil, err } @@ -1620,8 +2018,8 @@ func (_AutomationReceiver *AutomationReceiverFilterer) WatchSecurityWarning(opts select { case log := <-logs: - event := new(AutomationReceiverSecurityWarning) - if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { + event := new(AutomationReceiverPaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "Paused", log); err != nil { return err } event.Raw = log @@ -1642,104 +2040,647 @@ func (_AutomationReceiver *AutomationReceiverFilterer) WatchSecurityWarning(opts }), nil } -func (_AutomationReceiver *AutomationReceiverFilterer) ParseSecurityWarning(log types.Log) (*AutomationReceiverSecurityWarning, error) { - event := new(AutomationReceiverSecurityWarning) - if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { +func (_AutomationReceiver *AutomationReceiverFilterer) ParsePaused(log types.Log) (*AutomationReceiverPaused, error) { + event := new(AutomationReceiverPaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "Paused", log); err != nil { return nil, err } event.Raw = log return event, nil } -func (_AutomationReceiver *AutomationReceiver) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _AutomationReceiver.abi.Events["CallAllowedSet"].ID: - return _AutomationReceiver.ParseCallAllowedSet(log) - case _AutomationReceiver.abi.Events["CallExecuted"].ID: - return _AutomationReceiver.ParseCallExecuted(log) - case _AutomationReceiver.abi.Events["CallFailed"].ID: - return _AutomationReceiver.ParseCallFailed(log) - case _AutomationReceiver.abi.Events["ExpectedAuthorUpdated"].ID: - return _AutomationReceiver.ParseExpectedAuthorUpdated(log) - case _AutomationReceiver.abi.Events["ExpectedWorkflowIdUpdated"].ID: - return _AutomationReceiver.ParseExpectedWorkflowIdUpdated(log) - case _AutomationReceiver.abi.Events["ExpectedWorkflowNameUpdated"].ID: - return _AutomationReceiver.ParseExpectedWorkflowNameUpdated(log) - case _AutomationReceiver.abi.Events["ForwarderAddressUpdated"].ID: - return _AutomationReceiver.ParseForwarderAddressUpdated(log) - case _AutomationReceiver.abi.Events["OwnershipTransferred"].ID: - return _AutomationReceiver.ParseOwnershipTransferred(log) - case _AutomationReceiver.abi.Events["SecurityWarning"].ID: - return _AutomationReceiver.ParseSecurityWarning(log) +type AutomationReceiverReportSkippedWhilePausedIterator struct { + Event *AutomationReceiverReportSkippedWhilePaused - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} + contract *bind.BoundContract + event string -func (AutomationReceiverCallAllowedSet) Topic() common.Hash { - return common.HexToHash("0x0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7") + logs chan types.Log + sub ethereum.Subscription + done bool + fail error } -func (AutomationReceiverCallExecuted) Topic() common.Hash { - return common.HexToHash("0xbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb884") -} +func (it *AutomationReceiverReportSkippedWhilePausedIterator) Next() bool { -func (AutomationReceiverCallFailed) Topic() common.Hash { - return common.HexToHash("0xefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b6") -} + if it.fail != nil { + return false + } -func (AutomationReceiverExpectedAuthorUpdated) Topic() common.Hash { - return common.HexToHash("0x3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31") -} + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverReportSkippedWhilePaused) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true -func (AutomationReceiverExpectedWorkflowIdUpdated) Topic() common.Hash { - return common.HexToHash("0x0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03") -} + default: + return false + } + } -func (AutomationReceiverExpectedWorkflowNameUpdated) Topic() common.Hash { - return common.HexToHash("0x1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5") -} + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverReportSkippedWhilePaused) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true -func (AutomationReceiverForwarderAddressUpdated) Topic() common.Hash { - return common.HexToHash("0x039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e") + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } } -func (AutomationReceiverOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +func (it *AutomationReceiverReportSkippedWhilePausedIterator) Error() error { + return it.fail } -func (AutomationReceiverSecurityWarning) Topic() common.Hash { - return common.HexToHash("0x704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7") +func (it *AutomationReceiverReportSkippedWhilePausedIterator) Close() error { + it.sub.Unsubscribe() + return nil } -func (_AutomationReceiver *AutomationReceiver) Address() common.Address { - return _AutomationReceiver.address +type AutomationReceiverReportSkippedWhilePaused struct { + Raw types.Log } -type AutomationReceiverInterface interface { - GetExpectedAuthor(opts *bind.CallOpts) (common.Address, error) - - GetExpectedWorkflowId(opts *bind.CallOpts) ([32]byte, error) - - GetExpectedWorkflowName(opts *bind.CallOpts) ([10]byte, error) +func (_AutomationReceiver *AutomationReceiverFilterer) FilterReportSkippedWhilePaused(opts *bind.FilterOpts) (*AutomationReceiverReportSkippedWhilePausedIterator, error) { - GetForwarderAddress(opts *bind.CallOpts) (common.Address, error) + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "ReportSkippedWhilePaused") + if err != nil { + return nil, err + } + return &AutomationReceiverReportSkippedWhilePausedIterator{contract: _AutomationReceiver.contract, event: "ReportSkippedWhilePaused", logs: logs, sub: sub}, nil +} - IsCallAllowed(opts *bind.CallOpts, target common.Address, selector [4]byte) (bool, error) +func (_AutomationReceiver *AutomationReceiverFilterer) WatchReportSkippedWhilePaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverReportSkippedWhilePaused) (event.Subscription, error) { - Owner(opts *bind.CallOpts) (common.Address, error) + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "ReportSkippedWhilePaused") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: - SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + event := new(AutomationReceiverReportSkippedWhilePaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "ReportSkippedWhilePaused", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseReportSkippedWhilePaused(log types.Log) (*AutomationReceiverReportSkippedWhilePaused, error) { + event := new(AutomationReceiverReportSkippedWhilePaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "ReportSkippedWhilePaused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverSecurityWarningIterator struct { + Event *AutomationReceiverSecurityWarning + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverSecurityWarningIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverSecurityWarning) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverSecurityWarning) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverSecurityWarningIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverSecurityWarningIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverSecurityWarning struct { + Message string + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterSecurityWarning(opts *bind.FilterOpts) (*AutomationReceiverSecurityWarningIterator, error) { + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "SecurityWarning") + if err != nil { + return nil, err + } + return &AutomationReceiverSecurityWarningIterator{contract: _AutomationReceiver.contract, event: "SecurityWarning", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchSecurityWarning(opts *bind.WatchOpts, sink chan<- *AutomationReceiverSecurityWarning) (event.Subscription, error) { + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "SecurityWarning") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverSecurityWarning) + if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseSecurityWarning(log types.Log) (*AutomationReceiverSecurityWarning, error) { + event := new(AutomationReceiverSecurityWarning) + if err := _AutomationReceiver.contract.UnpackLog(event, "SecurityWarning", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverStaleReportSkippedIterator struct { + Event *AutomationReceiverStaleReportSkipped + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverStaleReportSkippedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverStaleReportSkipped) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverStaleReportSkipped) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverStaleReportSkippedIterator) Error() error { + return it.fail +} + +func (it *AutomationReceiverStaleReportSkippedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverStaleReportSkipped struct { + Target common.Address + Selector [4]byte + ReportBlockNumber *big.Int + LastReportBlock *big.Int + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterStaleReportSkipped(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverStaleReportSkippedIterator, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "StaleReportSkipped", targetRule, selectorRule) + if err != nil { + return nil, err + } + return &AutomationReceiverStaleReportSkippedIterator{contract: _AutomationReceiver.contract, event: "StaleReportSkipped", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchStaleReportSkipped(opts *bind.WatchOpts, sink chan<- *AutomationReceiverStaleReportSkipped, target []common.Address, selector [][4]byte) (event.Subscription, error) { + + var targetRule []interface{} + for _, targetItem := range target { + targetRule = append(targetRule, targetItem) + } + var selectorRule []interface{} + for _, selectorItem := range selector { + selectorRule = append(selectorRule, selectorItem) + } + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "StaleReportSkipped", targetRule, selectorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverStaleReportSkipped) + if err := _AutomationReceiver.contract.UnpackLog(event, "StaleReportSkipped", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseStaleReportSkipped(log types.Log) (*AutomationReceiverStaleReportSkipped, error) { + event := new(AutomationReceiverStaleReportSkipped) + if err := _AutomationReceiver.contract.UnpackLog(event, "StaleReportSkipped", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationReceiverUnpausedIterator struct { + Event *AutomationReceiverUnpaused + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationReceiverUnpausedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverUnpaused) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + default: + return false + } + } + + select { + case log := <-it.logs: + it.Event = new(AutomationReceiverUnpaused) + if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { + it.fail = err + return false + } + it.Event.Raw = log + return true + + case err := <-it.sub.Err(): + it.done = true + it.fail = err + return it.Next() + } +} + +func (it *AutomationReceiverUnpausedIterator) Error() error { + return it.fail +} - TypeAndVersion(opts *bind.CallOpts) (string, error) +func (it *AutomationReceiverUnpausedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationReceiverUnpaused struct { + Account common.Address + Raw types.Log +} + +func (_AutomationReceiver *AutomationReceiverFilterer) FilterUnpaused(opts *bind.FilterOpts) (*AutomationReceiverUnpausedIterator, error) { + + logs, sub, err := _AutomationReceiver.contract.FilterLogs(opts, "Unpaused") + if err != nil { + return nil, err + } + return &AutomationReceiverUnpausedIterator{contract: _AutomationReceiver.contract, event: "Unpaused", logs: logs, sub: sub}, nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverUnpaused) (event.Subscription, error) { + + logs, sub, err := _AutomationReceiver.contract.WatchLogs(opts, "Unpaused") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationReceiverUnpaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "Unpaused", log); err != nil { + return err + } + event.Raw = log + + select { + case sink <- event: + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + case err := <-sub.Err(): + return err + case <-quit: + return nil + } + } + }), nil +} + +func (_AutomationReceiver *AutomationReceiverFilterer) ParseUnpaused(log types.Log) (*AutomationReceiverUnpaused, error) { + event := new(AutomationReceiverUnpaused) + if err := _AutomationReceiver.contract.UnpackLog(event, "Unpaused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type GetBlockNumberCheck struct { + Enabled bool + LastReportBlock *big.Int +} + +func (_AutomationReceiver *AutomationReceiver) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _AutomationReceiver.abi.Events["BlockNumberCheckSet"].ID: + return _AutomationReceiver.ParseBlockNumberCheckSet(log) + case _AutomationReceiver.abi.Events["CallAllowedSet"].ID: + return _AutomationReceiver.ParseCallAllowedSet(log) + case _AutomationReceiver.abi.Events["CallExecuted"].ID: + return _AutomationReceiver.ParseCallExecuted(log) + case _AutomationReceiver.abi.Events["CallFailed"].ID: + return _AutomationReceiver.ParseCallFailed(log) + case _AutomationReceiver.abi.Events["ConsumerGasLimitSet"].ID: + return _AutomationReceiver.ParseConsumerGasLimitSet(log) + case _AutomationReceiver.abi.Events["ExpectedAuthorUpdated"].ID: + return _AutomationReceiver.ParseExpectedAuthorUpdated(log) + case _AutomationReceiver.abi.Events["ExpectedWorkflowIdUpdated"].ID: + return _AutomationReceiver.ParseExpectedWorkflowIdUpdated(log) + case _AutomationReceiver.abi.Events["ExpectedWorkflowNameUpdated"].ID: + return _AutomationReceiver.ParseExpectedWorkflowNameUpdated(log) + case _AutomationReceiver.abi.Events["ForwarderAddressUpdated"].ID: + return _AutomationReceiver.ParseForwarderAddressUpdated(log) + case _AutomationReceiver.abi.Events["OwnershipTransferred"].ID: + return _AutomationReceiver.ParseOwnershipTransferred(log) + case _AutomationReceiver.abi.Events["Paused"].ID: + return _AutomationReceiver.ParsePaused(log) + case _AutomationReceiver.abi.Events["ReportSkippedWhilePaused"].ID: + return _AutomationReceiver.ParseReportSkippedWhilePaused(log) + case _AutomationReceiver.abi.Events["SecurityWarning"].ID: + return _AutomationReceiver.ParseSecurityWarning(log) + case _AutomationReceiver.abi.Events["StaleReportSkipped"].ID: + return _AutomationReceiver.ParseStaleReportSkipped(log) + case _AutomationReceiver.abi.Events["Unpaused"].ID: + return _AutomationReceiver.ParseUnpaused(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (AutomationReceiverBlockNumberCheckSet) Topic() common.Hash { + return common.HexToHash("0xf19a6052943cc4c32e1644d475a7b4e6f517bcae63159220028f5de68d6d0364") +} + +func (AutomationReceiverCallAllowedSet) Topic() common.Hash { + return common.HexToHash("0x0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7") +} + +func (AutomationReceiverCallExecuted) Topic() common.Hash { + return common.HexToHash("0xbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb884") +} + +func (AutomationReceiverCallFailed) Topic() common.Hash { + return common.HexToHash("0xefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b6") +} + +func (AutomationReceiverConsumerGasLimitSet) Topic() common.Hash { + return common.HexToHash("0xf3f16b36d6fb2a97e5e66d28e758a4d457e80197e1d455f692a96be32091fa3a") +} + +func (AutomationReceiverExpectedAuthorUpdated) Topic() common.Hash { + return common.HexToHash("0x3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31") +} + +func (AutomationReceiverExpectedWorkflowIdUpdated) Topic() common.Hash { + return common.HexToHash("0x0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03") +} + +func (AutomationReceiverExpectedWorkflowNameUpdated) Topic() common.Hash { + return common.HexToHash("0x1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5") +} + +func (AutomationReceiverForwarderAddressUpdated) Topic() common.Hash { + return common.HexToHash("0x039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e") +} + +func (AutomationReceiverOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (AutomationReceiverPaused) Topic() common.Hash { + return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") +} + +func (AutomationReceiverReportSkippedWhilePaused) Topic() common.Hash { + return common.HexToHash("0xf37c389ae9f5e13dbbef9f62b1ad0893e89c865ee834b2e221d11ebcf3cacd51") +} + +func (AutomationReceiverSecurityWarning) Topic() common.Hash { + return common.HexToHash("0x704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf7") +} + +func (AutomationReceiverStaleReportSkipped) Topic() common.Hash { + return common.HexToHash("0x96e22437f0b9d1dfe909221668f6ad9813c1128b60a7b4b3dee74e4248df834a") +} + +func (AutomationReceiverUnpaused) Topic() common.Hash { + return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") +} + +func (_AutomationReceiver *AutomationReceiver) Address() common.Address { + return _AutomationReceiver.address +} + +type AutomationReceiverInterface interface { + GetBlockNumberCheck(opts *bind.CallOpts, target common.Address, selector [4]byte) (GetBlockNumberCheck, + + error) + + GetConsumerGasLimit(opts *bind.CallOpts, target common.Address, selector [4]byte) (*big.Int, error) + + GetExpectedAuthor(opts *bind.CallOpts) (common.Address, error) + + GetExpectedWorkflowId(opts *bind.CallOpts) ([32]byte, error) + + GetExpectedWorkflowName(opts *bind.CallOpts) ([10]byte, error) + + GetForwarderAddress(opts *bind.CallOpts) (common.Address, error) + + IsCallAllowed(opts *bind.CallOpts, target common.Address, selector [4]byte) (bool, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + Paused(opts *bind.CallOpts) (bool, error) + + RetryableWhilePaused(opts *bind.CallOpts) (bool, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) OnReport(opts *bind.TransactOpts, metadata []byte, report []byte) (*types.Transaction, error) + Pause(opts *bind.TransactOpts, retryable bool) (*types.Transaction, error) + RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + SetBlockNumberCheck(opts *bind.TransactOpts, target common.Address, selector [4]byte, enabled bool, initialBlockNumber *big.Int) (*types.Transaction, error) + SetCallAllowed(opts *bind.TransactOpts, target common.Address, selector [4]byte, allowed bool) (*types.Transaction, error) + SetConsumerGasLimit(opts *bind.TransactOpts, target common.Address, selector [4]byte, gasLimit *big.Int) (*types.Transaction, error) + SetExpectedAuthor(opts *bind.TransactOpts, _author common.Address) (*types.Transaction, error) SetExpectedWorkflowId(opts *bind.TransactOpts, _id [32]byte) (*types.Transaction, error) @@ -1750,6 +2691,14 @@ type AutomationReceiverInterface interface { TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) + Unpause(opts *bind.TransactOpts) (*types.Transaction, error) + + FilterBlockNumberCheckSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverBlockNumberCheckSetIterator, error) + + WatchBlockNumberCheckSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverBlockNumberCheckSet, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseBlockNumberCheckSet(log types.Log) (*AutomationReceiverBlockNumberCheckSet, error) + FilterCallAllowedSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverCallAllowedSetIterator, error) WatchCallAllowedSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverCallAllowedSet, target []common.Address, selector [][4]byte) (event.Subscription, error) @@ -1768,6 +2717,12 @@ type AutomationReceiverInterface interface { ParseCallFailed(log types.Log) (*AutomationReceiverCallFailed, error) + FilterConsumerGasLimitSet(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverConsumerGasLimitSetIterator, error) + + WatchConsumerGasLimitSet(opts *bind.WatchOpts, sink chan<- *AutomationReceiverConsumerGasLimitSet, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseConsumerGasLimitSet(log types.Log) (*AutomationReceiverConsumerGasLimitSet, error) + FilterExpectedAuthorUpdated(opts *bind.FilterOpts, previousAuthor []common.Address, newAuthor []common.Address) (*AutomationReceiverExpectedAuthorUpdatedIterator, error) WatchExpectedAuthorUpdated(opts *bind.WatchOpts, sink chan<- *AutomationReceiverExpectedAuthorUpdated, previousAuthor []common.Address, newAuthor []common.Address) (event.Subscription, error) @@ -1798,12 +2753,36 @@ type AutomationReceiverInterface interface { ParseOwnershipTransferred(log types.Log) (*AutomationReceiverOwnershipTransferred, error) + FilterPaused(opts *bind.FilterOpts) (*AutomationReceiverPausedIterator, error) + + WatchPaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverPaused) (event.Subscription, error) + + ParsePaused(log types.Log) (*AutomationReceiverPaused, error) + + FilterReportSkippedWhilePaused(opts *bind.FilterOpts) (*AutomationReceiverReportSkippedWhilePausedIterator, error) + + WatchReportSkippedWhilePaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverReportSkippedWhilePaused) (event.Subscription, error) + + ParseReportSkippedWhilePaused(log types.Log) (*AutomationReceiverReportSkippedWhilePaused, error) + FilterSecurityWarning(opts *bind.FilterOpts) (*AutomationReceiverSecurityWarningIterator, error) WatchSecurityWarning(opts *bind.WatchOpts, sink chan<- *AutomationReceiverSecurityWarning) (event.Subscription, error) ParseSecurityWarning(log types.Log) (*AutomationReceiverSecurityWarning, error) + FilterStaleReportSkipped(opts *bind.FilterOpts, target []common.Address, selector [][4]byte) (*AutomationReceiverStaleReportSkippedIterator, error) + + WatchStaleReportSkipped(opts *bind.WatchOpts, sink chan<- *AutomationReceiverStaleReportSkipped, target []common.Address, selector [][4]byte) (event.Subscription, error) + + ParseStaleReportSkipped(log types.Log) (*AutomationReceiverStaleReportSkipped, error) + + FilterUnpaused(opts *bind.FilterOpts) (*AutomationReceiverUnpausedIterator, error) + + WatchUnpaused(opts *bind.WatchOpts, sink chan<- *AutomationReceiverUnpaused) (event.Subscription, error) + + ParseUnpaused(log types.Log) (*AutomationReceiverUnpaused, error) + ParseLog(log types.Log) (generated.AbigenLog, error) Address() common.Address diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index ed149b5c9e..9afad90fa5 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 -automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin fd174c01998b44055471666fdf1d31e247ce9b32f9fcf920710cc7026cfbeec0 +automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin 5f0975cb7d2b36ae2cf844f903a9c771ba8b141cf73086e5379c2f438f6070bd automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef From b93f75a17530497a7522225853d7d2cc2b1be2d8 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Wed, 8 Jul 2026 14:40:29 -0300 Subject: [PATCH 12/29] Update IERC165 --- contracts/src/v0.8/automation/IERC165.sol | 33 ++++++++++++++++------- 1 file changed, 24 insertions(+), 9 deletions(-) diff --git a/contracts/src/v0.8/automation/IERC165.sol b/contracts/src/v0.8/automation/IERC165.sol index 9af4bf800f..47aca8d133 100644 --- a/contracts/src/v0.8/automation/IERC165.sol +++ b/contracts/src/v0.8/automation/IERC165.sol @@ -1,12 +1,27 @@ // SPDX-License-Identifier: MIT -pragma solidity >=0.6.2; +// OpenZeppelin Contracts (last updated v5.4.0) (utils/introspection/IERC165.sol) +pragma solidity >=0.4.16; + +/** + * @dev Interface of the ERC-165 standard, as defined in the + * https://eips.ethereum.org/EIPS/eip-165[ERC]. + * + * Implementers can declare support of contract interfaces, which can then be + * queried by others ({ERC165Checker}). + * + * For an implementation, see {ERC165}. + */ interface IERC165 { - /// @notice Query if a contract implements an interface - /// @param interfaceID The interface identifier, as specified in ERC-165 - /// @dev Interface identification is specified in ERC-165. This function - /// uses less than 30,000 gas. - /// @return `true` if the contract implements `interfaceID` and - /// `interfaceID` is not 0xffffffff, `false` otherwise - function supportsInterface(bytes4 interfaceID) external view returns (bool); -} + /** + * @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[ERC 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); +} \ No newline at end of file From f5e651cadd083929da3d3864de6bd295ad297d30 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Wed, 8 Jul 2026 14:48:14 -0300 Subject: [PATCH 13/29] Change version --- contracts/src/v0.8/automation/AutomationReceiver.sol | 4 ++-- contracts/src/v0.8/automation/ReceiverTemplate.sol | 4 ++-- .../generated/automation_receiver/automation_receiver.go | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index ecfcf4e099..48c266e3d8 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT -pragma solidity 0.8.26; +pragma solidity 0.8.24; import "./ReceiverTemplate.sol"; -import {Pausable} from "@openzeppelin/contracts/utils/Pausable.sol"; +import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; /** * @title AutomationReceiver diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index 57b792a3f4..240e021aec 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; +pragma solidity ^0.8.24; import {IERC165} from "./IERC165.sol"; import {IReceiver} from "./IReceiver.sol"; -import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol"; +import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; /// @title ReceiverTemplate - Abstract receiver with optional permission controls /// @notice Provides flexible, updatable security checks for receiving workflow reports diff --git a/gethwrappers/generated/automation_receiver/automation_receiver.go b/gethwrappers/generated/automation_receiver/automation_receiver.go index b67d4a04b8..540767fffb 100644 --- a/gethwrappers/generated/automation_receiver/automation_receiver.go +++ b/gethwrappers/generated/automation_receiver/automation_receiver.go @@ -32,7 +32,7 @@ var ( var AutomationReceiverMetaData = &bind.MetaData{ ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"getBlockNumberCheck\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"enabled\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"lastReportBlock\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getConsumerGasLimit\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedAuthor\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowId\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getExpectedWorkflowName\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getForwarderAddress\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"isCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"onReport\",\"inputs\":[{\"name\":\"metadata\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"report\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pause\",\"inputs\":[{\"name\":\"retryable\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"retryableWhilePaused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"setBlockNumberCheck\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"enabled\",\"type\":\"bool\",\"internalType\":\"bool\"},{\"name\":\"initialBlockNumber\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setCallAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setConsumerGasLimit\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"},{\"name\":\"gasLimit\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedAuthor\",\"inputs\":[{\"name\":\"_author\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowId\",\"inputs\":[{\"name\":\"_id\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setExpectedWorkflowName\",\"inputs\":[{\"name\":\"_name\",\"type\":\"string\",\"internalType\":\"string\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setForwarderAddress\",\"inputs\":[{\"name\":\"_forwarder\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"supportsInterface\",\"inputs\":[{\"name\":\"interfaceId\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"unpause\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"BlockNumberCheckSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"enabled\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"},{\"name\":\"initialBlockNumber\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallAllowedSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"allowed\",\"type\":\"bool\",\"indexed\":false,\"internalType\":\"bool\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallExecuted\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"returnData\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CallFailed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reason\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ConsumerGasLimitSet\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"previousLimit\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"newLimit\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedAuthorUpdated\",\"inputs\":[{\"name\":\"previousAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newAuthor\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowIdUpdated\",\"inputs\":[{\"name\":\"previousId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"newId\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ExpectedWorkflowNameUpdated\",\"inputs\":[{\"name\":\"previousName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"},{\"name\":\"newName\",\"type\":\"bytes10\",\"indexed\":true,\"internalType\":\"bytes10\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ForwarderAddressUpdated\",\"inputs\":[{\"name\":\"previousForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newForwarder\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Paused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ReportSkippedWhilePaused\",\"inputs\":[],\"anonymous\":false},{\"type\":\"event\",\"name\":\"SecurityWarning\",\"inputs\":[{\"name\":\"message\",\"type\":\"string\",\"indexed\":false,\"internalType\":\"string\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"StaleReportSkipped\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"indexed\":true,\"internalType\":\"bytes4\"},{\"name\":\"reportBlockNumber\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"lastReportBlock\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Unpaused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"error\",\"name\":\"CallNotAllowed\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"selector\",\"type\":\"bytes4\",\"internalType\":\"bytes4\"}]},{\"type\":\"error\",\"name\":\"EnforcedPause\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"ExpectedPause\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InsufficientGas\",\"inputs\":[{\"name\":\"available\",\"type\":\"uint256\",\"internalType\":\"uint256\"},{\"name\":\"required\",\"type\":\"uint256\",\"internalType\":\"uint256\"}]},{\"type\":\"error\",\"name\":\"InvalidAuthor\",\"inputs\":[{\"name\":\"received\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidForwarderAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidSender\",\"inputs\":[{\"name\":\"sender\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"expected\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"InvalidTargetAddress\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"InvalidWorkflowId\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"expected\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}]},{\"type\":\"error\",\"name\":\"InvalidWorkflowName\",\"inputs\":[{\"name\":\"received\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"},{\"name\":\"expected\",\"type\":\"bytes10\",\"internalType\":\"bytes10\"}]},{\"type\":\"error\",\"name\":\"MissingSelector\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"OwnableInvalidOwner\",\"inputs\":[{\"name\":\"owner\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"OwnableUnauthorizedAccount\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"TargetHasNoCode\",\"inputs\":[{\"name\":\"target\",\"type\":\"address\",\"internalType\":\"address\"}]},{\"type\":\"error\",\"name\":\"WorkflowIdentityNotConfigured\",\"inputs\":[]},{\"type\":\"error\",\"name\":\"WorkflowNameRequiresAuthorValidation\",\"inputs\":[]}]", - Bin: "0x608060405234801561000f575f80fd5b506040516124d03803806124d083398101604081905261002e9161012c565b80338061005457604051631e4fbdf760e01b81525f600482015260240160405180910390fd5b61005d816100dd565b506001600160a01b0381166100845760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040515f907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a350506004805460ff19169055610159565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f6020828403121561013c575f80fd5b81516001600160a01b0381168114610152575f80fd5b9392505050565b61236a806101665f395ff3fe608060405234801561000f575f80fd5b5060043610610184575f3560e01c80638da5cb5b116100dd578063c3c44ac211610088578063d8fb859411610063578063d8fb859414610429578063f2fde38b14610453578063f5c793ef14610466575f80fd5b8063c3c44ac2146103f0578063d60c884b14610403578063d777cc6d14610416575f80fd5b8063b25de11e116100b8578063b25de11e146103bf578063bc1fc27a146103ca578063c2f7510d146103dd575f80fd5b80638da5cb5b146103405780639c1c77ca1461035d578063a619d81814610370575f80fd5b80635c975abb1161013d578063797c8d6911610118578063797c8d6914610250578063805f2132146102b9578063851ca9c1146102cc575f80fd5b80635c975abb1461022a578063715018a61461023557806375483caf1461023d575f80fd5b80633397cf671161016d5780633397cf67146101c55780633441856f146102045780633f4ba83a14610222575f80fd5b806301ffc9a71461018857806302329a29146101b0575b5f80fd5b61019b610196366004611def565b61046e565b60405190151581526020015b60405180910390f35b6101c36101be366004611e1e565b610506565b005b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101a7565b60015473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c3610545565b60045460ff1661019b565b6101c3610557565b6101c361024b366004611e58565b610568565b61019b61025e366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526005602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101c36102c7366004611f13565b6106ec565b6103326102da366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526006602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205492915050565b6040519081526020016101a7565b5f5473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c361036b366004611f7f565b610aab565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff0000000000000000000000000000000000000000000090911681526020016101a7565b60095460ff1661019b565b6101c36103d8366004611fc1565b610c2a565b6101c36103eb366004612000565b610e98565b6101c36103fe36600461203c565b610f85565b6101c3610411366004612053565b610fc5565b6101c3610424366004612053565b611043565b61043c610437366004611ea2565b611170565b6040805192151583526020830191909152016101a7565b6101c3610461366004612053565b6111e5565b600354610332565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f805f213200000000000000000000000000000000000000000000000000000000148061050057507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b61050e611245565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016821515179055610542611297565b50565b61054d611245565b61055561131c565b565b61055f611245565b6105555f611373565b610570611245565b73ffffffffffffffffffffffffffffffffffffffff84166105bd576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168452909152812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001684151517905582610643575f610651565b811561064f5781610651565b435b73ffffffffffffffffffffffffffffffffffffffff86165f8181526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008a16808552908352928190208590558051881515815291820185905293945090927ff19a6052943cc4c32e1644d475a7b4e6f517bcae63159220028f5de68d6d0364910160405180910390a35050505050565b60015473ffffffffffffffffffffffffffffffffffffffff161580159061072b575060015473ffffffffffffffffffffffffffffffffffffffff163314155b15610789576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b6003541515806107b0575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806107f9575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b15610a9b575f805f61083f87878080601f0160208091040260200160405190810160405280939291908181526020018383808284375f920191909152506113e792505050565b60035492955090935091501580159061085a57506003548314155b1561089f576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610780918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff16158015906108e1575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b1561093c576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610780565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615610a975760025473ffffffffffffffffffffffffffffffffffffffff166109d0576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610a97576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610780565b5050505b610aa58282611400565b50505050565b610ab3611245565b73ffffffffffffffffffffffffffffffffffffffff8316610b00576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b808015610b22575073ffffffffffffffffffffffffffffffffffffffff83163b155b15610b71576040517ffff2336100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84166004820152602401610780565b73ffffffffffffffffffffffffffffffffffffffff83165f8181526005602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b610c32611245565b60025474010000000000000000000000000000000000000000900460b01b5f829003610cd357600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040515f907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b5f60028484604051610ce692919061206e565b602060405180830381855afa158015610d01573d5f803e3d5ffd5b5050506040513d601f19601f82011682018060405250810190610d24919061207d565b90505f610d5182604051602001610d3d91815260200190565b604051602081830303815290604052611af3565b60408051600a8082528183019092529192505f91906020820181803683370190505090505f5b600a811015610de557828181518110610d9257610d926120c1565b602001015160f81c60f81b828281518110610daf57610daf6120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101610d77565b50610def816120ee565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5905f90a3505050505050565b610ea0611245565b73ffffffffffffffffffffffffffffffffffffffff8316610eed576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83165f8181526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000871680855290835292819020805490869055815181815292830186905293917ff3f16b36d6fb2a97e5e66d28e758a4d457e80197e1d455f692a96be32091fa3a910160405180910390a350505050565b610f8d611245565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03905f90a35050565b610fcd611245565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31905f90a35050565b61104b611245565b60015473ffffffffffffffffffffffffffffffffffffffff9081169082166110fb577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf76040516110f29060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e905f90a35050565b73ffffffffffffffffffffffffffffffffffffffff82165f8181526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008616808552908352818420549484526008835281842090845290915290205460ff909116905b9250929050565b6111ed611245565b73ffffffffffffffffffffffffffffffffffffffff811661123c576040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081525f6004820152602401610780565b61054281611373565b5f5473ffffffffffffffffffffffffffffffffffffffff163314610555576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610780565b61129f611d42565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586112f23390565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b611324611d7f565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa336112f2565b5f805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b60045460ff16156114745760095460ff1615611448576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517ff37c389ae9f5e13dbbef9f62b1ad0893e89c865ee834b2e221d11ebcf3cacd51905f90a15050565b60015473ffffffffffffffffffffffffffffffffffffffff166114c3576040517f381dd54000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600354158015611530575060025473ffffffffffffffffffffffffffffffffffffffff161580611530575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016155b15611567576040517f8ec26f9a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f80806115768486018661215a565b9194509250905073ffffffffffffffffffffffffffffffffffffffff83166115ca576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015611606576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff85165f9081526005835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff166116d6576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff851660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610780565b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff161561185e5773ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000085168452909152902054808410156118085760408051858152602081018390527fffffffff0000000000000000000000000000000000000000000000000000000084169173ffffffffffffffffffffffffffffffffffffffff8816917f96e22437f0b9d1dfe909221668f6ad9813c1128b60a7b4b3dee74e4248df834a910160405180910390a350505050505050565b5073ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290208390555b73ffffffffffffffffffffffffffffffffffffffff84165f9081526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000851684529091528120549060608215611996575f611b586118c8603f86612292565b6118d290866122ca565b6118dc91906122ca565b9050805a1015611924575a6040517f23e228cb000000000000000000000000000000000000000000000000000000008152600481019190915260248101829052604401610780565b8773ffffffffffffffffffffffffffffffffffffffff16848760405161194a91906122dd565b5f604051808303815f8787f1925050503d805f8114611984576040519150601f19603f3d011682016040523d82523d5f602084013e611989565b606091505b509093509150611a009050565b8673ffffffffffffffffffffffffffffffffffffffff16856040516119bb91906122dd565b5f604051808303815f865af19150503d805f81146119f4576040519150601f19603f3d011682016040523d82523d5f602084013e6119f9565b606091505b5090925090505b8115611a7957837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb88483604051611a6c91906122f3565b60405180910390a3611ae8565b837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b683604051611adf91906122f3565b60405180910390a35b505050505050505050565b60605f82516002611b049190612346565b67ffffffffffffffff811115611b1c57611b1c612094565b6040519080825280601f01601f191660200182016040528015611b46576020820181803683370190505b5090505f5b8351811015611d3b576040518060400160405280601081526020017f30313233343536373839616263646566000000000000000000000000000000008152506004858381518110611b9e57611b9e6120c1565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c908110611bde57611bde6120c1565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611c11836002612346565b81518110611c2157611c216120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053506040518060400160405280601081526020017f3031323334353637383961626364656600000000000000000000000000000000815250848281518110611c9757611c976120c1565b602091010151815160f89190911c600f16908110611cb757611cb76120c1565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611cea836002612346565b611cf59060016122ca565b81518110611d0557611d056120c1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101611b4b565b5092915050565b60045460ff1615610555576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60045460ff16610555576040517f8dfc202b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80357fffffffff0000000000000000000000000000000000000000000000000000000081168114611dea575f80fd5b919050565b5f60208284031215611dff575f80fd5b611e0882611dbb565b9392505050565b80358015158114611dea575f80fd5b5f60208284031215611e2e575f80fd5b611e0882611e0f565b73ffffffffffffffffffffffffffffffffffffffff81168114610542575f80fd5b5f805f8060808587031215611e6b575f80fd5b8435611e7681611e37565b9350611e8460208601611dbb565b9250611e9260408601611e0f565b9396929550929360600135925050565b5f8060408385031215611eb3575f80fd5b8235611ebe81611e37565b9150611ecc60208401611dbb565b90509250929050565b5f8083601f840112611ee5575f80fd5b50813567ffffffffffffffff811115611efc575f80fd5b6020830191508360208285010111156111de575f80fd5b5f805f8060408587031215611f26575f80fd5b843567ffffffffffffffff811115611f3c575f80fd5b611f4887828801611ed5565b909550935050602085013567ffffffffffffffff811115611f67575f80fd5b611f7387828801611ed5565b95989497509550505050565b5f805f60608486031215611f91575f80fd5b8335611f9c81611e37565b9250611faa60208501611dbb565b9150611fb860408501611e0f565b90509250925092565b5f8060208385031215611fd2575f80fd5b823567ffffffffffffffff811115611fe8575f80fd5b611ff485828601611ed5565b90969095509350505050565b5f805f60608486031215612012575f80fd5b833561201d81611e37565b925061202b60208501611dbb565b929592945050506040919091013590565b5f6020828403121561204c575f80fd5b5035919050565b5f60208284031215612063575f80fd5b8135611e0881611e37565b818382375f9101908152919050565b5f6020828403121561208d575f80fd5b5051919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b805160208201517fffffffffffffffffffff0000000000000000000000000000000000000000000081169190600a821015612153577fffffffffffffffffffff000000000000000000000000000000000000000000008083600a0360031b1b82161692505b5050919050565b5f805f6060848603121561216c575f80fd5b833561217781611e37565b925060208401359150604084013567ffffffffffffffff811115612199575f80fd5b8401601f810186136121a9575f80fd5b803567ffffffffffffffff8111156121c3576121c3612094565b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8501160116810181811067ffffffffffffffff8211171561222f5761222f612094565b604052818152828201602001881015612246575f80fd5b816020840160208301375f602083830101528093505050509250925092565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f826122c5577f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b500490565b8082018082111561050057610500612265565b5f82518060208501845e5f920191825250919050565b602081525f82518060208401528060208501604085015e5f6040828501015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011684010191505092915050565b80820281158282048414176105005761050061226556fea164736f6c634300081a000a", + Bin: "0x608060405234801562000010575f80fd5b50604051620024b7380380620024b7833981016040819052620000339162000136565b8033806200005a57604051631e4fbdf760e01b81525f600482015260240160405180910390fd5b6200006581620000e7565b506001600160a01b0381166200008d5760405162e0775560e61b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b0383169081179091556040515f907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e908290a350506004805460ff1916905562000165565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f6020828403121562000147575f80fd5b81516001600160a01b03811681146200015e575f80fd5b9392505050565b61234480620001735f395ff3fe608060405234801561000f575f80fd5b5060043610610184575f3560e01c80638da5cb5b116100dd578063c3c44ac211610088578063d8fb859411610063578063d8fb859414610429578063f2fde38b14610453578063f5c793ef14610466575f80fd5b8063c3c44ac2146103f0578063d60c884b14610403578063d777cc6d14610416575f80fd5b8063b25de11e116100b8578063b25de11e146103bf578063bc1fc27a146103ca578063c2f7510d146103dd575f80fd5b80638da5cb5b146103405780639c1c77ca1461035d578063a619d81814610370575f80fd5b80635c975abb1161013d578063797c8d6911610118578063797c8d6914610250578063805f2132146102b9578063851ca9c1146102cc575f80fd5b80635c975abb1461022a578063715018a61461023557806375483caf1461023d575f80fd5b80633397cf671161016d5780633397cf67146101c55780633441856f146102045780633f4ba83a14610222575f80fd5b806301ffc9a71461018857806302329a29146101b0575b5f80fd5b61019b610196366004611def565b61046e565b60405190151581526020015b60405180910390f35b6101c36101be366004611e1e565b610506565b005b60025473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101a7565b60015473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c3610545565b60045460ff1661019b565b6101c3610557565b6101c361024b366004611e58565b610568565b61019b61025e366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526005602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff1692915050565b6101c36102c7366004611f13565b6106ec565b6103326102da366004611ea2565b73ffffffffffffffffffffffffffffffffffffffff82165f9081526006602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205492915050565b6040519081526020016101a7565b5f5473ffffffffffffffffffffffffffffffffffffffff166101df565b6101c361036b366004611f7a565b610aab565b60025474010000000000000000000000000000000000000000900460b01b6040517fffffffffffffffffffff0000000000000000000000000000000000000000000090911681526020016101a7565b60095460ff1661019b565b6101c36103d8366004611fbc565b610c2a565b6101c36103eb366004611ffb565b610e98565b6101c36103fe366004612036565b610f85565b6101c361041136600461204d565b610fc5565b6101c361042436600461204d565b611043565b61043c610437366004611ea2565b611170565b6040805192151583526020830191909152016101a7565b6101c361046136600461204d565b6111e5565b600354610332565b5f7fffffffff0000000000000000000000000000000000000000000000000000000082167f805f213200000000000000000000000000000000000000000000000000000000148061050057507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b61050e611245565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016821515179055610542611297565b50565b61054d611245565b61055561131c565b565b61055f611245565b6105555f611373565b610570611245565b73ffffffffffffffffffffffffffffffffffffffff84166105bd576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168452909152812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001684151517905582610643575f610651565b811561064f5781610651565b435b73ffffffffffffffffffffffffffffffffffffffff86165f8181526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008a16808552908352928190208590558051881515815291820185905293945090927ff19a6052943cc4c32e1644d475a7b4e6f517bcae63159220028f5de68d6d0364910160405180910390a35050505050565b60015473ffffffffffffffffffffffffffffffffffffffff161580159061072b575060015473ffffffffffffffffffffffffffffffffffffffff163314155b15610789576001546040517fe1130dba00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b6003541515806107b0575060025473ffffffffffffffffffffffffffffffffffffffff1615155b806107f9575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615155b15610a9b575f805f61083f87878080601f0160208091040260200160405190810160405280939291908181526020018383808284375f920191909152506113e792505050565b60035492955090935091501580159061085a57506003548314155b1561089f576003546040517f9bfa39ba000000000000000000000000000000000000000000000000000000008152610780918591600401918252602082015260400190565b60025473ffffffffffffffffffffffffffffffffffffffff16158015906108e1575060025473ffffffffffffffffffffffffffffffffffffffff828116911614155b1561093c576002546040517fb8a98af800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff80841660048301529091166024820152604401610780565b60025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff000000000000000000000000000000000000000000001615610a975760025473ffffffffffffffffffffffffffffffffffffffff166109d0576040517f4847901100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002547fffffffffffffffffffff000000000000000000000000000000000000000000008381167401000000000000000000000000000000000000000090920460b01b1614610a97576002546040517f6c4609a60000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffff0000000000000000000000000000000000000000000084811660048301527401000000000000000000000000000000000000000090920460b01b9091166024820152604401610780565b5050505b610aa58282611400565b50505050565b610ab3611245565b73ffffffffffffffffffffffffffffffffffffffff8316610b00576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b808015610b22575073ffffffffffffffffffffffffffffffffffffffff83163b155b15610b71576040517ffff2336100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84166004820152602401610780565b73ffffffffffffffffffffffffffffffffffffffff83165f8181526005602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000087168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915590519081529192917f0925d576b7c865d78d7fe746ae46d080d64b9e6b04db5f034f71a79c41dda2e7910160405180910390a3505050565b610c32611245565b60025474010000000000000000000000000000000000000000900460b01b5f829003610cd357600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff1690556040515f907fffffffffffffffffffff000000000000000000000000000000000000000000008316907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5908390a3505050565b5f60028484604051610ce6929190612068565b602060405180830381855afa158015610d01573d5f803e3d5ffd5b5050506040513d601f19601f82011682018060405250810190610d249190612077565b90505f610d5182604051602001610d3d91815260200190565b604051602081830303815290604052611af3565b60408051600a8082528183019092529192505f91906020820181803683370190505090505f5b600a811015610de557828181518110610d9257610d926120bb565b602001015160f81c60f81b828281518110610daf57610daf6120bb565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101610d77565b50610def816120e8565b600280547fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000060b093841c81029190911791829055604051910490911b7fffffffffffffffffffff0000000000000000000000000000000000000000000090811691908616907f1e7ddd09d504c82dcfc784a464b167469f5aad967606ec4822d848ef9141dfa5905f90a3505050505050565b610ea0611245565b73ffffffffffffffffffffffffffffffffffffffff8316610eed576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83165f8181526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000871680855290835292819020805490869055815181815292830186905293917ff3f16b36d6fb2a97e5e66d28e758a4d457e80197e1d455f692a96be32091fa3a910160405180910390a350505050565b610f8d611245565b6003805490829055604051829082907f0dbedcdf21925e053b4c574eae180d7f2883235ab4976ecc0873598a2a999b03905f90a35050565b610fcd611245565b6002805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f3321cda85c145617e47418aa14255e9dcbec53a753778e57591703b89a3cad31905f90a35050565b61104b611245565b60015473ffffffffffffffffffffffffffffffffffffffff9081169082166110fb577f704da7db165c79c1e33d542c079333bbde970a733032d2f95fec8fb7d770cbf76040516110f29060208082526038908201527f466f7277617264657220616464726573732073657420746f207a65726f202d2060408201527f636f6e7472616374206973206e6f7720494e5345435552450000000000000000606082015260800190565b60405180910390a15b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84811691821790925560405190918316907f039ad854736757070884dd787ef1a7f58db33546639d1f3efddcf4a33fb8997e905f90a35050565b73ffffffffffffffffffffffffffffffffffffffff82165f8181526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008616808552908352818420549484526008835281842090845290915290205460ff909116905b9250929050565b6111ed611245565b73ffffffffffffffffffffffffffffffffffffffff811661123c576040517f1e4fbdf70000000000000000000000000000000000000000000000000000000081525f6004820152602401610780565b61054281611373565b5f5473ffffffffffffffffffffffffffffffffffffffff163314610555576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610780565b61129f611d42565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586112f23390565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b611324611d7f565b600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa336112f2565b5f805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60208101516040820151604a83015160601c9193909250565b60045460ff16156114745760095460ff1615611448576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517ff37c389ae9f5e13dbbef9f62b1ad0893e89c865ee834b2e221d11ebcf3cacd51905f90a15050565b60015473ffffffffffffffffffffffffffffffffffffffff166114c3576040517f381dd54000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600354158015611530575060025473ffffffffffffffffffffffffffffffffffffffff161580611530575060025474010000000000000000000000000000000000000000900460b01b7fffffffffffffffffffff0000000000000000000000000000000000000000000016155b15611567576040517f8ec26f9a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5f808061157684860186612137565b9194509250905073ffffffffffffffffffffffffffffffffffffffff83166115ca576040517ff1a492cc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600481511015611606576040517f47d7741900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208181015173ffffffffffffffffffffffffffffffffffffffff85165f9081526005835260408082207fffffffff0000000000000000000000000000000000000000000000000000000084168352909352919091205460ff166116d6576040517f805043f900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff851660048201527fffffffff0000000000000000000000000000000000000000000000000000000082166024820152604401610780565b73ffffffffffffffffffffffffffffffffffffffff84165f9081526007602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290205460ff161561185e5773ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff0000000000000000000000000000000000000000000000000000000085168452909152902054808410156118085760408051858152602081018390527fffffffff0000000000000000000000000000000000000000000000000000000084169173ffffffffffffffffffffffffffffffffffffffff8816917f96e22437f0b9d1dfe909221668f6ad9813c1128b60a7b4b3dee74e4248df834a910160405180910390a350505050505050565b5073ffffffffffffffffffffffffffffffffffffffff84165f9081526008602090815260408083207fffffffff000000000000000000000000000000000000000000000000000000008516845290915290208390555b73ffffffffffffffffffffffffffffffffffffffff84165f9081526006602090815260408083207fffffffff00000000000000000000000000000000000000000000000000000000851684529091528120549060608215611996575f611b586118c8603f86612248565b6118d29086612280565b6118dc9190612280565b9050805a1015611924575a6040517f23e228cb000000000000000000000000000000000000000000000000000000008152600481019190915260248101829052604401610780565b8773ffffffffffffffffffffffffffffffffffffffff16848760405161194a91906122b5565b5f604051808303815f8787f1925050503d805f8114611984576040519150601f19603f3d011682016040523d82523d5f602084013e611989565b606091505b509093509150611a009050565b8673ffffffffffffffffffffffffffffffffffffffff16856040516119bb91906122b5565b5f604051808303815f865af19150503d805f81146119f4576040519150601f19603f3d011682016040523d82523d5f602084013e6119f9565b606091505b5090925090505b8115611a7957837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fbe82131bb3404498c769b0511da41a4ad409fa7152562c2b6669241cbe3bb88483604051611a6c91906122d0565b60405180910390a3611ae8565b837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19168773ffffffffffffffffffffffffffffffffffffffff167fefa88af289a36b936ccacf9bd9eaaa185775cd54ae263973d3579c01111593b683604051611adf91906122d0565b60405180910390a35b505050505050505050565b60605f82516002611b049190612320565b67ffffffffffffffff811115611b1c57611b1c61208e565b6040519080825280601f01601f191660200182016040528015611b46576020820181803683370190505b5090505f5b8351811015611d3b576040518060400160405280601081526020017f30313233343536373839616263646566000000000000000000000000000000008152506004858381518110611b9e57611b9e6120bb565b016020015182517fff0000000000000000000000000000000000000000000000000000000000000090911690911c60f81c908110611bde57611bde6120bb565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611c11836002612320565b81518110611c2157611c216120bb565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a9053506040518060400160405280601081526020017f3031323334353637383961626364656600000000000000000000000000000000815250848281518110611c9757611c976120bb565b602091010151815160f89190911c600f16908110611cb757611cb76120bb565b01602001517fff000000000000000000000000000000000000000000000000000000000000001682611cea836002612320565b611cf5906001612280565b81518110611d0557611d056120bb565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191690815f1a905350600101611b4b565b5092915050565b60045460ff1615610555576040517fd93c066500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60045460ff16610555576040517f8dfc202b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80357fffffffff0000000000000000000000000000000000000000000000000000000081168114611dea575f80fd5b919050565b5f60208284031215611dff575f80fd5b611e0882611dbb565b9392505050565b80358015158114611dea575f80fd5b5f60208284031215611e2e575f80fd5b611e0882611e0f565b73ffffffffffffffffffffffffffffffffffffffff81168114610542575f80fd5b5f805f8060808587031215611e6b575f80fd5b8435611e7681611e37565b9350611e8460208601611dbb565b9250611e9260408601611e0f565b9396929550929360600135925050565b5f8060408385031215611eb3575f80fd5b8235611ebe81611e37565b9150611ecc60208401611dbb565b90509250929050565b5f8083601f840112611ee5575f80fd5b50813567ffffffffffffffff811115611efc575f80fd5b6020830191508360208285010111156111de575f80fd5b5f805f8060408587031215611f26575f80fd5b843567ffffffffffffffff80821115611f3d575f80fd5b611f4988838901611ed5565b90965094506020870135915080821115611f61575f80fd5b50611f6e87828801611ed5565b95989497509550505050565b5f805f60608486031215611f8c575f80fd5b8335611f9781611e37565b9250611fa560208501611dbb565b9150611fb360408501611e0f565b90509250925092565b5f8060208385031215611fcd575f80fd5b823567ffffffffffffffff811115611fe3575f80fd5b611fef85828601611ed5565b90969095509350505050565b5f805f6060848603121561200d575f80fd5b833561201881611e37565b925061202660208501611dbb565b9150604084013590509250925092565b5f60208284031215612046575f80fd5b5035919050565b5f6020828403121561205d575f80fd5b8135611e0881611e37565b818382375f9101908152919050565b5f60208284031215612087575f80fd5b5051919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52603260045260245ffd5b5f815160208301517fffffffffffffffffffff000000000000000000000000000000000000000000008082169350600a83101561212f57808184600a0360031b1b83161693505b505050919050565b5f805f60608486031215612149575f80fd5b833561215481611e37565b925060208401359150604084013567ffffffffffffffff80821115612177575f80fd5b818601915086601f83011261218a575f80fd5b81358181111561219c5761219c61208e565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156121e2576121e261208e565b816040528281528960208487010111156121fa575f80fd5b826020860160208301375f6020848301015280955050505050509250925092565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f8261227b577f4e487b71000000000000000000000000000000000000000000000000000000005f52601260045260245ffd5b500490565b808201808211156105005761050061221b565b5f5b838110156122ad578181015183820152602001612295565b50505f910152565b5f82516122c6818460208701612293565b9190910192915050565b602081525f82518060208401526122ee816040850160208701612293565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b80820281158282048414176105005761050061221b56fea164736f6c6343000818000a", } var AutomationReceiverABI = AutomationReceiverMetaData.ABI diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 9afad90fa5..21058cfad8 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 -automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin 5f0975cb7d2b36ae2cf844f903a9c771ba8b141cf73086e5379c2f438f6070bd +automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin c8d03ed089c8a4734d4cb7146852b3b323177dc0d47f7f3c23d436af3c3a062b automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef From 22dcc8896f599a4a30780652bdeae9fbb4e73cc7 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Wed, 8 Jul 2026 14:53:41 -0300 Subject: [PATCH 14/29] Run Forge fmt --- .../v0.8/automation/AutomationReceiver.sol | 676 +++++++++--------- contracts/src/v0.8/automation/IERC165.sol | 2 +- contracts/src/v0.8/automation/IReceiver.sol | 7 +- .../src/v0.8/automation/ReceiverTemplate.sol | 7 +- 4 files changed, 347 insertions(+), 345 deletions(-) diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 48c266e3d8..72f5619e59 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -28,363 +28,371 @@ import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; * Migration rule of thumb: inbound authorizes the workflow; outbound authorizes the action. */ contract AutomationReceiver is ReceiverTemplate, Pausable { - // Non-target gas costs reserved by the guard (gasleft() < required). - // GAS_OVERHEAD covers only the post-check path: everything from the gasleft() - // comparison through function return. The s_consumerGasLimit SLOAD immediately - // preceding the check is NOT included — it is already reflected in the lower - // gasleft() value at the check point and must not be double-counted. - // - // [Post-check — must complete with remaining gas at the guard point:] - // Pre-call ops (GAS, ADD, LT, JUMPI, stack) ~50 - // CALL to target (cold account access — in production ~2,600 - // setCallAllowed runs in an earlier transaction, so - // the target account has not yet been touched in the - // delivery transaction and the CALL pays the full - // EIP-2929 cold-access surcharge, not the ~100 warm rate) - // Post-call (success flag, JUMPI, LOG3) ~2,200 - // ├─ LOG3 base + 3 topics (375 + 3×375) 1,500 - // ├─ LOG3 data (64 B ABI-encoded empty bytes) 512 - // └─ misc (returnData mem, JUMPI, stack) 188 - // Misc stack / memory ~50 - // Subtotal: ~4,900 - // Conservative headroom (future opcode repricing, ~2,100 - // estimation error) - // Total: ~7,000 - // - // EIP-150 (63/64 rule): a CALL can forward at most 63/64 of available gas. - // Without the `consumerGasLimit / 63` term, the guard under-provisions whenever - // consumerGasLimit > 63 × GAS_OVERHEAD (~441,000). _processReport therefore adds - // consumerGasLimit / 63 to `required` dynamically so that: - // 63/64 × available ≥ consumerGasLimit - // - // Pre-guard overhead (paid BEFORE the check point, so NOT part of `required`): - // Up to four cold SLOADs in ReceiverTemplate.onReport when identity checks are - // active (s_forwarderAddress, s_expectedWorkflowId, s_expectedAuthor, - // s_expectedWorkflowName: 4 × 2,100 = 8,400 gas), warm re-reads of those slots - // in _processReport (~400 gas), abi.decode of the report (~300 gas), the cold - // nested-mapping read of s_callAllowed (~4,200 gas on first access), a cold - // s_consumerGasLimit SLOAD (~2,100 gas), and paused() (~2,100 gas cold) add up to - // ~17,500 gas on the first delivery to a pair. After slots warm, pre-guard drops to - // ~5,500 gas. When the block-number monotonicity check is enabled for a pair, budget - // a further ~10,000 gas for its two cold SLOADs and the advancing SSTORE. - // - // This pre-guard gas is intentionally NOT added to `required` and needs no per-feature constant: - // it is spent before `gasleft()` is read, so the guard already sees it (it observes the reduced - // remaining gas) and cannot manufacture it. Adding it to `required` would double-count and cause - // spurious InsufficientGas reverts. The only caller-side action is to size writeGasLimit to cover - // this pre-guard overhead on top of consumerGasLimit + GAS_OVERHEAD (see README Gas Limit - // section). Under-budgeting fails cleanly (InsufficientGas if the guard is reached, otherwise - // OOG) — both are recorded by the Forwarder as retryable, so this is a tuning, not a safety, - // concern. - uint256 private constant GAS_OVERHEAD = 7000; + // Non-target gas costs reserved by the guard (gasleft() < required). + // GAS_OVERHEAD covers only the post-check path: everything from the gasleft() + // comparison through function return. The s_consumerGasLimit SLOAD immediately + // preceding the check is NOT included — it is already reflected in the lower + // gasleft() value at the check point and must not be double-counted. + // + // [Post-check — must complete with remaining gas at the guard point:] + // Pre-call ops (GAS, ADD, LT, JUMPI, stack) ~50 + // CALL to target (cold account access — in production ~2,600 + // setCallAllowed runs in an earlier transaction, so + // the target account has not yet been touched in the + // delivery transaction and the CALL pays the full + // EIP-2929 cold-access surcharge, not the ~100 warm rate) + // Post-call (success flag, JUMPI, LOG3) ~2,200 + // ├─ LOG3 base + 3 topics (375 + 3×375) 1,500 + // ├─ LOG3 data (64 B ABI-encoded empty bytes) 512 + // └─ misc (returnData mem, JUMPI, stack) 188 + // Misc stack / memory ~50 + // Subtotal: ~4,900 + // Conservative headroom (future opcode repricing, ~2,100 + // estimation error) + // Total: ~7,000 + // + // EIP-150 (63/64 rule): a CALL can forward at most 63/64 of available gas. + // Without the `consumerGasLimit / 63` term, the guard under-provisions whenever + // consumerGasLimit > 63 × GAS_OVERHEAD (~441,000). _processReport therefore adds + // consumerGasLimit / 63 to `required` dynamically so that: + // 63/64 × available ≥ consumerGasLimit + // + // Pre-guard overhead (paid BEFORE the check point, so NOT part of `required`): + // Up to four cold SLOADs in ReceiverTemplate.onReport when identity checks are + // active (s_forwarderAddress, s_expectedWorkflowId, s_expectedAuthor, + // s_expectedWorkflowName: 4 × 2,100 = 8,400 gas), warm re-reads of those slots + // in _processReport (~400 gas), abi.decode of the report (~300 gas), the cold + // nested-mapping read of s_callAllowed (~4,200 gas on first access), a cold + // s_consumerGasLimit SLOAD (~2,100 gas), and paused() (~2,100 gas cold) add up to + // ~17,500 gas on the first delivery to a pair. After slots warm, pre-guard drops to + // ~5,500 gas. When the block-number monotonicity check is enabled for a pair, budget + // a further ~10,000 gas for its two cold SLOADs and the advancing SSTORE. + // + // This pre-guard gas is intentionally NOT added to `required` and needs no per-feature constant: + // it is spent before `gasleft()` is read, so the guard already sees it (it observes the reduced + // remaining gas) and cannot manufacture it. Adding it to `required` would double-count and cause + // spurious InsufficientGas reverts. The only caller-side action is to size writeGasLimit to cover + // this pre-guard overhead on top of consumerGasLimit + GAS_OVERHEAD (see README Gas Limit + // section). Under-budgeting fails cleanly (InsufficientGas if the guard is reached, otherwise + // OOG) — both are recorded by the Forwarder as retryable, so this is a tuning, not a safety, + // concern. + uint256 private constant GAS_OVERHEAD = 7000; - /// @notice Closed-by-default allowlist of callable (target, selector) pairs. - mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; + /// @notice Closed-by-default allowlist of callable (target, selector) pairs. + mapping(address target => mapping(bytes4 selector => bool allowed)) private s_callAllowed; - /// @notice Per-(target, selector) minimum gas the consumer needs to execute. 0 = no limit. - mapping(address target => mapping(bytes4 selector => uint256 gasLimit)) private s_consumerGasLimit; + /// @notice Per-(target, selector) minimum gas the consumer needs to execute. 0 = no limit. + mapping(address target => mapping(bytes4 selector => uint256 gasLimit)) private s_consumerGasLimit; - /// @notice Opt-in per-(target, selector) block-number monotonicity switch. Closed by default. - mapping(address target => mapping(bytes4 selector => bool enabled)) private s_blockNumberCheckEnabled; + /// @notice Opt-in per-(target, selector) block-number monotonicity switch. Closed by default. + mapping(address target => mapping(bytes4 selector => bool enabled)) private s_blockNumberCheckEnabled; - /// @notice Highest report block number accepted so far for a (target, selector) pair. Doubles as - /// the configurable initial floor set by {setBlockNumberCheck}. - mapping(address target => mapping(bytes4 selector => uint256 blockNumber)) private s_lastReportBlock; - /// @notice While paused, controls how incoming reports are handled. The owner picks the mode - /// at {pause} time: true = reverts (reports stay unconsumed and retryable, resuming - /// after {unpause}); false = the report is consumed (dropped, not retried). Only - /// meaningful while {paused} is true. - bool private s_retryableWhilePaused; + /// @notice Highest report block number accepted so far for a (target, selector) pair. Doubles as + /// the configurable initial floor set by {setBlockNumberCheck}. + mapping(address target => mapping(bytes4 selector => uint256 blockNumber)) private s_lastReportBlock; + /// @notice While paused, controls how incoming reports are handled. The owner picks the mode + /// at {pause} time: true = reverts (reports stay unconsumed and retryable, resuming + /// after {unpause}); false = the report is consumed (dropped, not retried). Only + /// meaningful while {paused} is true. + bool private s_retryableWhilePaused; - /// @notice Emitted when a target call succeeds. - event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); - /// @notice Emitted when an allowed target call reverts. The report is still consumed. - event CallFailed(address indexed target, bytes4 indexed selector, bytes reason); - /// @notice Emitted when the owner updates the outbound allowlist. - event CallAllowedSet(address indexed target, bytes4 indexed selector, bool allowed); - /// @notice Emitted when the owner updates the consumer gas limit for a (target, selector) pair. - event ConsumerGasLimitSet(address indexed target, bytes4 indexed selector, uint256 previousLimit, uint256 newLimit); - /// @notice Emitted when the owner enables/disables the block-number monotonicity check for a pair. - /// When enabled, `initialBlockNumber` is the floor the next report must meet or exceed. - event BlockNumberCheckSet(address indexed target, bytes4 indexed selector, bool enabled, uint256 initialBlockNumber); - /// @notice Emitted when a report is skipped because its block number is older than the last - /// accepted one for the pair. The report is consumed (not reverted), mirroring - /// Chainlink Automation's fire-and-forget semantics. - event StaleReportSkipped(address indexed target, bytes4 indexed selector, uint256 reportBlockNumber, uint256 lastReportBlock); - /// @notice Emitted when a report is dropped (consumed, not retried) because the receiver is - /// paused in non-retryable mode (see {pause}). - event ReportSkippedWhilePaused(); + /// @notice Emitted when a target call succeeds. + event CallExecuted(address indexed target, bytes4 indexed selector, bytes returnData); + /// @notice Emitted when an allowed target call reverts. The report is still consumed. + event CallFailed(address indexed target, bytes4 indexed selector, bytes reason); + /// @notice Emitted when the owner updates the outbound allowlist. + event CallAllowedSet(address indexed target, bytes4 indexed selector, bool allowed); + /// @notice Emitted when the owner updates the consumer gas limit for a (target, selector) pair. + event ConsumerGasLimitSet(address indexed target, bytes4 indexed selector, uint256 previousLimit, uint256 newLimit); + /// @notice Emitted when the owner enables/disables the block-number monotonicity check for a pair. + /// When enabled, `initialBlockNumber` is the floor the next report must meet or exceed. + event BlockNumberCheckSet(address indexed target, bytes4 indexed selector, bool enabled, uint256 initialBlockNumber); + /// @notice Emitted when a report is skipped because its block number is older than the last + /// accepted one for the pair. The report is consumed (not reverted), mirroring + /// Chainlink Automation's fire-and-forget semantics. + event StaleReportSkipped( + address indexed target, bytes4 indexed selector, uint256 reportBlockNumber, uint256 lastReportBlock + ); + /// @notice Emitted when a report is dropped (consumed, not retried) because the receiver is + /// paused in non-retryable mode (see {pause}). + event ReportSkippedWhilePaused(); - /// @notice Thrown when the decoded target is the zero address. - error InvalidTargetAddress(); - /// @notice Thrown when the target address has no deployed code (EOA, mistyped address, or never-deployed contract). - error TargetHasNoCode(address target); - /// @notice Thrown when the report carries fewer than 4 bytes of calldata (no selector). - error MissingSelector(); - /// @notice Thrown when (target, selector) is not on the outbound allowlist. - error CallNotAllowed(address target, bytes4 selector); - /// @notice Thrown when there is not enough gas to safely forward consumerGasLimit to the target. - /// Causes the forwarder to record the transmission as failed so it can be retried. - error InsufficientGas(uint256 available, uint256 required); - /// @notice Thrown when onReport is called without a complete workflow identity configuration. - /// The receiver requires at least one of the two valid options to be satisfied - /// (satisfying both is also fine): - /// (1) workflowId is set, or (2) both workflowOwner and workflowName are set. - /// Without at least one complete option the receiver cannot be bound to a specific - /// workflow and would accept reports from any DON-signed payload. - error WorkflowIdentityNotConfigured(); + /// @notice Thrown when the decoded target is the zero address. + error InvalidTargetAddress(); + /// @notice Thrown when the target address has no deployed code (EOA, mistyped address, or never-deployed contract). + error TargetHasNoCode(address target); + /// @notice Thrown when the report carries fewer than 4 bytes of calldata (no selector). + error MissingSelector(); + /// @notice Thrown when (target, selector) is not on the outbound allowlist. + error CallNotAllowed(address target, bytes4 selector); + /// @notice Thrown when there is not enough gas to safely forward consumerGasLimit to the target. + /// Causes the forwarder to record the transmission as failed so it can be retried. + error InsufficientGas(uint256 available, uint256 required); + /// @notice Thrown when onReport is called without a complete workflow identity configuration. + /// The receiver requires at least one of the two valid options to be satisfied + /// (satisfying both is also fine): + /// (1) workflowId is set, or (2) both workflowOwner and workflowName are set. + /// Without at least one complete option the receiver cannot be bound to a specific + /// workflow and would accept reports from any DON-signed payload. + error WorkflowIdentityNotConfigured(); - constructor(address _forwarder) ReceiverTemplate(_forwarder) {} + constructor( + address _forwarder + ) ReceiverTemplate(_forwarder) {} - /// @notice Emergency stop: halt all report processing until {unpause} is called. Owner-only. - /// @dev Global equivalent of Chainlink Automation's registry-wide pause. DON pause/delete only - /// stops NEW reports; already-signed reports remain permissionlessly deliverable, and this - /// on-chain switch also rejects those in-flight reports. The owner chooses, per pause, how - /// reports that arrive while paused are handled via `retryable`: - /// - `retryable = true`: `_processReport` reverts with `EnforcedPause`. The revert bubbles - /// up through `onReport`, so the CRE Forwarder records the transmission as failed and it - /// stays retryable — pending reports resume delivery once {unpause} is called. - /// - `retryable = false`: `_processReport` emits `ReportSkippedWhilePaused` and returns, - /// consuming the report. Such reports are dropped and will NOT be redelivered after - /// {unpause}. Use this when a backlog of retried reports would be undesirable. - /// @param retryable Whether reports delivered while paused should remain retryable (true) or be - /// dropped (false). The chosen mode applies until the next {pause} or {unpause}. - function pause(bool retryable) external onlyOwner { - s_retryableWhilePaused = retryable; - _pause(); - } + /// @notice Emergency stop: halt all report processing until {unpause} is called. Owner-only. + /// @dev Global equivalent of Chainlink Automation's registry-wide pause. DON pause/delete only + /// stops NEW reports; already-signed reports remain permissionlessly deliverable, and this + /// on-chain switch also rejects those in-flight reports. The owner chooses, per pause, how + /// reports that arrive while paused are handled via `retryable`: + /// - `retryable = true`: `_processReport` reverts with `EnforcedPause`. The revert bubbles + /// up through `onReport`, so the CRE Forwarder records the transmission as failed and it + /// stays retryable — pending reports resume delivery once {unpause} is called. + /// - `retryable = false`: `_processReport` emits `ReportSkippedWhilePaused` and returns, + /// consuming the report. Such reports are dropped and will NOT be redelivered after + /// {unpause}. Use this when a backlog of retried reports would be undesirable. + /// @param retryable Whether reports delivered while paused should remain retryable (true) or be + /// dropped (false). The chosen mode applies until the next {pause} or {unpause}. + function pause( + bool retryable + ) external onlyOwner { + s_retryableWhilePaused = retryable; + _pause(); + } - /// @notice Resume report processing after a {pause}. Owner-only. - function unpause() external onlyOwner { - _unpause(); - } + /// @notice Resume report processing after a {pause}. Owner-only. + function unpause() external onlyOwner { + _unpause(); + } - /// @notice Returns the pause mode selected at the last {pause}: true if reports delivered while - /// paused revert (retryable), false if they are dropped. Only meaningful while paused. - function retryableWhilePaused() external view returns (bool) { - return s_retryableWhilePaused; - } + /// @notice Returns the pause mode selected at the last {pause}: true if reports delivered while + /// paused revert (retryable), false if they are dropped. Only meaningful while paused. + function retryableWhilePaused() external view returns (bool) { + return s_retryableWhilePaused; + } - /// @notice Allow or disallow the receiver to call `selector` on `target`. - /// @dev Closed by default. Register every (target, selector) the migrated upkeep needs, - /// e.g. `performUpkeep(bytes)` for custom-logic/log upkeeps, or your specific - /// time-based function. Owner-only. - /// When `allowed` is true, validates that `target` has deployed code at the time of - /// registration; passing an EOA, a mistyped address, or a never-deployed address reverts - /// with `TargetHasNoCode`. The check is skipped when `allowed` is false so that an - /// allowlist entry can always be revoked, even if the target has since self-destructed - /// and its code has become empty. - /// @param target The contract the receiver is permitted to call. - /// @param selector The 4-byte function selector permitted on `target`. - /// @param allowed True to permit, false to revoke. - function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { - if (target == address(0)) { - revert InvalidTargetAddress(); - } - if (allowed && target.code.length == 0) { - revert TargetHasNoCode(target); - } - s_callAllowed[target][selector] = allowed; - emit CallAllowedSet(target, selector, allowed); + /// @notice Allow or disallow the receiver to call `selector` on `target`. + /// @dev Closed by default. Register every (target, selector) the migrated upkeep needs, + /// e.g. `performUpkeep(bytes)` for custom-logic/log upkeeps, or your specific + /// time-based function. Owner-only. + /// When `allowed` is true, validates that `target` has deployed code at the time of + /// registration; passing an EOA, a mistyped address, or a never-deployed address reverts + /// with `TargetHasNoCode`. The check is skipped when `allowed` is false so that an + /// allowlist entry can always be revoked, even if the target has since self-destructed + /// and its code has become empty. + /// @param target The contract the receiver is permitted to call. + /// @param selector The 4-byte function selector permitted on `target`. + /// @param allowed True to permit, false to revoke. + function setCallAllowed(address target, bytes4 selector, bool allowed) external onlyOwner { + if (target == address(0)) { + revert InvalidTargetAddress(); } - - /// @notice Returns whether the receiver may call `selector` on `target`. - function isCallAllowed(address target, bytes4 selector) external view returns (bool) { - return s_callAllowed[target][selector]; + if (allowed && target.code.length == 0) { + revert TargetHasNoCode(target); } + s_callAllowed[target][selector] = allowed; + emit CallAllowedSet(target, selector, allowed); + } - /// @notice Set the minimum gas required to execute `selector` on `target`. - /// @dev When non-zero, `_processReport` will revert with `InsufficientGas` before calling - /// the target if available gas is below `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. - /// The `gasLimit / 63` term compensates for the EIP-150 (63/64) rule: a CALL can - /// forward at most 63/64 of the available gas, so without this buffer a high gas limit - /// would cause the target to receive less than `gasLimit`. This causes the CRE - /// Forwarder to record the transmission as failed (retryable) rather than permanently - /// consuming the report. Set this to the `performGasLimit` tuned in Automation for the - /// specific function being migrated. Each (target, selector) pair has its own limit. - /// Zero (the default) disables the guard for that pair and preserves fire-and-forget. - /// Note: the on-chain formula only covers costs from the guard check onward. The - /// workflow's writeGasLimit must also budget for pre-guard overhead (~17,500 gas - /// on the first delivery to a pair, ~5,500 gas thereafter) on top of this limit. - /// @param target The contract the limit applies to. Must not be the zero address. - /// @param selector The 4-byte function selector the limit applies to. - /// @param gasLimit Minimum gas required by the consumer. 0 = no guard. - function setConsumerGasLimit(address target, bytes4 selector, uint256 gasLimit) external onlyOwner { - if (target == address(0)) revert InvalidTargetAddress(); - uint256 previous = s_consumerGasLimit[target][selector]; - s_consumerGasLimit[target][selector] = gasLimit; - emit ConsumerGasLimitSet(target, selector, previous, gasLimit); - } + /// @notice Returns whether the receiver may call `selector` on `target`. + function isCallAllowed(address target, bytes4 selector) external view returns (bool) { + return s_callAllowed[target][selector]; + } - /// @notice Returns the configured consumer gas limit for a (target, selector) pair (0 = no guard). - function getConsumerGasLimit(address target, bytes4 selector) external view returns (uint256) { - return s_consumerGasLimit[target][selector]; - } + /// @notice Set the minimum gas required to execute `selector` on `target`. + /// @dev When non-zero, `_processReport` will revert with `InsufficientGas` before calling + /// the target if available gas is below `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. + /// The `gasLimit / 63` term compensates for the EIP-150 (63/64) rule: a CALL can + /// forward at most 63/64 of the available gas, so without this buffer a high gas limit + /// would cause the target to receive less than `gasLimit`. This causes the CRE + /// Forwarder to record the transmission as failed (retryable) rather than permanently + /// consuming the report. Set this to the `performGasLimit` tuned in Automation for the + /// specific function being migrated. Each (target, selector) pair has its own limit. + /// Zero (the default) disables the guard for that pair and preserves fire-and-forget. + /// Note: the on-chain formula only covers costs from the guard check onward. The + /// workflow's writeGasLimit must also budget for pre-guard overhead (~17,500 gas + /// on the first delivery to a pair, ~5,500 gas thereafter) on top of this limit. + /// @param target The contract the limit applies to. Must not be the zero address. + /// @param selector The 4-byte function selector the limit applies to. + /// @param gasLimit Minimum gas required by the consumer. 0 = no guard. + function setConsumerGasLimit(address target, bytes4 selector, uint256 gasLimit) external onlyOwner { + if (target == address(0)) revert InvalidTargetAddress(); + uint256 previous = s_consumerGasLimit[target][selector]; + s_consumerGasLimit[target][selector] = gasLimit; + emit ConsumerGasLimitSet(target, selector, previous, gasLimit); + } - /// @notice Enable or disable the block-number monotonicity (staleness) check for a (target, selector). - /// @dev Closed by default. When enabled, `_processReport` rejects any report whose encoded block - /// number is strictly less than the last accepted one for the pair (CLA-parity: a report at - /// the same block is still accepted). Stale reports are consumed, not reverted, so the - /// forwarder does not pointlessly retry an always-stale delivery. - /// - /// Under Chainlink Automation the registry rejected any report whose trigger block preceded - /// the last performed block. The CRE delivery path does not preserve this ordering, so this - /// opt-in check restores it for conditional-trigger / log upkeeps that relied on it. The - /// workflow always encodes a block number in the report payload, so this can be turned on - /// later without any workflow change. - /// - /// When enabling, the initial floor is configurable: - /// - `initialBlockNumber == 0`: snapshot the current `block.number` as the floor. Note this - /// does NOT reject reports minted between deployment/config and the moment this check is - /// enabled if they carry a block number above the snapshot; prefer an explicit floor when - /// that matters. - /// - `initialBlockNumber != 0`: use the provided value as the floor. - /// The very first accepted report must have a block number >= this floor. - /// - /// Disabling (enabled = false) resets the floor to 0, so out-of-order reports execute - /// again going forward. This is NOT retroactive: a report already rejected as stale while - /// the check was enabled was consumed at that moment (see `StaleReportSkipped`) and is gone - /// — the CRE Forwarder does not hold it for redelivery. Turning the check off cannot revive - /// it; only reports the workflow re-submits after disabling will be considered. - /// Each (target, selector) pair is configured independently. Owner-only. - /// @param target The contract the check applies to. Must not be the zero address. - /// @param selector The 4-byte function selector the check applies to. - /// @param enabled True to enable the check, false to disable it (and clear the stored floor). - /// @param initialBlockNumber Floor for the first report when enabling; 0 snapshots `block.number`. - function setBlockNumberCheck(address target, bytes4 selector, bool enabled, uint256 initialBlockNumber) - external - onlyOwner - { - if (target == address(0)) revert InvalidTargetAddress(); - s_blockNumberCheckEnabled[target][selector] = enabled; - uint256 floor = enabled ? (initialBlockNumber == 0 ? block.number : initialBlockNumber) : 0; - s_lastReportBlock[target][selector] = floor; - emit BlockNumberCheckSet(target, selector, enabled, floor); - } + /// @notice Returns the configured consumer gas limit for a (target, selector) pair (0 = no guard). + function getConsumerGasLimit(address target, bytes4 selector) external view returns (uint256) { + return s_consumerGasLimit[target][selector]; + } + + /// @notice Enable or disable the block-number monotonicity (staleness) check for a (target, selector). + /// @dev Closed by default. When enabled, `_processReport` rejects any report whose encoded block + /// number is strictly less than the last accepted one for the pair (CLA-parity: a report at + /// the same block is still accepted). Stale reports are consumed, not reverted, so the + /// forwarder does not pointlessly retry an always-stale delivery. + /// + /// Under Chainlink Automation the registry rejected any report whose trigger block preceded + /// the last performed block. The CRE delivery path does not preserve this ordering, so this + /// opt-in check restores it for conditional-trigger / log upkeeps that relied on it. The + /// workflow always encodes a block number in the report payload, so this can be turned on + /// later without any workflow change. + /// + /// When enabling, the initial floor is configurable: + /// - `initialBlockNumber == 0`: snapshot the current `block.number` as the floor. Note this + /// does NOT reject reports minted between deployment/config and the moment this check is + /// enabled if they carry a block number above the snapshot; prefer an explicit floor when + /// that matters. + /// - `initialBlockNumber != 0`: use the provided value as the floor. + /// The very first accepted report must have a block number >= this floor. + /// + /// Disabling (enabled = false) resets the floor to 0, so out-of-order reports execute + /// again going forward. This is NOT retroactive: a report already rejected as stale while + /// the check was enabled was consumed at that moment (see `StaleReportSkipped`) and is gone + /// — the CRE Forwarder does not hold it for redelivery. Turning the check off cannot revive + /// it; only reports the workflow re-submits after disabling will be considered. + /// Each (target, selector) pair is configured independently. Owner-only. + /// @param target The contract the check applies to. Must not be the zero address. + /// @param selector The 4-byte function selector the check applies to. + /// @param enabled True to enable the check, false to disable it (and clear the stored floor). + /// @param initialBlockNumber Floor for the first report when enabling; 0 snapshots `block.number`. + function setBlockNumberCheck( + address target, + bytes4 selector, + bool enabled, + uint256 initialBlockNumber + ) external onlyOwner { + if (target == address(0)) revert InvalidTargetAddress(); + s_blockNumberCheckEnabled[target][selector] = enabled; + uint256 floor = enabled ? (initialBlockNumber == 0 ? block.number : initialBlockNumber) : 0; + s_lastReportBlock[target][selector] = floor; + emit BlockNumberCheckSet(target, selector, enabled, floor); + } + + /// @notice Returns the block-number monotonicity configuration for a (target, selector) pair. + /// @return enabled Whether the check is active. + /// @return lastReportBlock The highest report block number accepted so far (or the floor set when + /// the check was enabled, if no report has been accepted since). + function getBlockNumberCheck( + address target, + bytes4 selector + ) external view returns (bool enabled, uint256 lastReportBlock) { + return (s_blockNumberCheckEnabled[target][selector], s_lastReportBlock[target][selector]); + } - /// @notice Returns the block-number monotonicity configuration for a (target, selector) pair. - /// @return enabled Whether the check is active. - /// @return lastReportBlock The highest report block number accepted so far (or the floor set when - /// the check was enabled, if no report has been accepted since). - function getBlockNumberCheck(address target, bytes4 selector) - external - view - returns (bool enabled, uint256 lastReportBlock) + /// @notice Decodes and executes the call on the target contract. + /// @param report ABI-encoded (address target, uint256 blockNumber, bytes data), where + /// `blockNumber` is the block the report was produced for (used only by the opt-in + /// monotonicity check) and `data` is a full function call (4-byte selector followed by its + /// arguments) executed as `target.call(data)`. + /// @dev Two pre-conditions are enforced before any decoding: + /// 1. The forwarder address must not be zero. `ReceiverTemplate.setForwarderAddress` + /// does not block address(0), so this guard closes that gap: if the owner ever + /// sets the forwarder to zero (disabling the caller check in onReport), every + /// subsequent report delivery is rejected here instead. + /// 2. A complete workflow identity option must be configured. Two options are accepted: + /// (a) workflowId is set — binds the receiver to one specific workflow instance; or + /// (b) both workflowOwner and workflowName are set — binds the receiver to a named + /// workflow from a specific owner. Either piece of option (b) alone is insufficient: + /// owner alone allows any workflow from that owner; name alone is globally ambiguous. + /// Requiring a complete option closes the cross-receiver replay vector from audit M-02. + /// Authorization failures (zero target, missing selector, not-allowlisted) revert loudly — + /// they indicate misconfiguration or a malformed report. Execution failures (an allowed call that + /// reverts) are swallowed: `CallFailed` is emitted and the report is consumed, matching + /// Chainlink Automation's fire-and-forget semantics where the next trigger re-evaluates + /// eligibility. + /// Staleness: when the block-number monotonicity check is enabled for the pair (see + /// {setBlockNumberCheck}), a report whose block number is older than the last accepted one + /// is skipped — `StaleReportSkipped` is emitted and the report is consumed without executing + /// the target call or reverting. + /// Gas-guard: when `s_consumerGasLimit[target][selector]` is non-zero, the function + /// reverts with `InsufficientGas` before the target call if available gas is below + /// `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. The `gasLimit / 63` term accounts for + /// the EIP-150 (63/64) rule: a CALL forwards at most 63/64 of available gas, so + /// without this buffer a high gas limit (above ~441,000) would cause the target to + /// receive less than configured. This ensures a low-gas delivery is recorded as failed + /// by the forwarder and can be retried, preventing griefing attacks. Each + /// (target, selector) pair has its own configurable limit. + /// Pause guard: when the contract is paused (see {pause}), this function short-circuits + /// before any decoding or execution, and its behavior depends on the mode the owner + /// selected at pause time. In retryable mode it reverts with `EnforcedPause` (the revert + /// propagates through `onReport`, so the forwarder records the transmission as failed and + /// it resumes after {unpause}). In non-retryable mode it emits `ReportSkippedWhilePaused` + /// and returns, consuming (dropping) the report so it is not redelivered. + function _processReport( + bytes calldata report + ) internal override { + if (paused()) { + if (s_retryableWhilePaused) { + revert EnforcedPause(); + } + emit ReportSkippedWhilePaused(); + return; + } + // Read the inherited permission fields directly (warm SLOADs). ReceiverTemplate.onReport + // already loaded all four slots before dispatching here, so these reads cost ~100 gas + // each — far cheaper than a self-STATICCALL to the external getters. + if (s_forwarderAddress == address(0)) { + revert InvalidForwarderAddress(); + } + if (s_expectedWorkflowId == bytes32(0) && (s_expectedAuthor == address(0) || s_expectedWorkflowName == bytes10(0))) { - return (s_blockNumberCheckEnabled[target][selector], s_lastReportBlock[target][selector]); + revert WorkflowIdentityNotConfigured(); } - /// @notice Decodes and executes the call on the target contract. - /// @param report ABI-encoded (address target, uint256 blockNumber, bytes data), where - /// `blockNumber` is the block the report was produced for (used only by the opt-in - /// monotonicity check) and `data` is a full function call (4-byte selector followed by its - /// arguments) executed as `target.call(data)`. - /// @dev Two pre-conditions are enforced before any decoding: - /// 1. The forwarder address must not be zero. `ReceiverTemplate.setForwarderAddress` - /// does not block address(0), so this guard closes that gap: if the owner ever - /// sets the forwarder to zero (disabling the caller check in onReport), every - /// subsequent report delivery is rejected here instead. - /// 2. A complete workflow identity option must be configured. Two options are accepted: - /// (a) workflowId is set — binds the receiver to one specific workflow instance; or - /// (b) both workflowOwner and workflowName are set — binds the receiver to a named - /// workflow from a specific owner. Either piece of option (b) alone is insufficient: - /// owner alone allows any workflow from that owner; name alone is globally ambiguous. - /// Requiring a complete option closes the cross-receiver replay vector from audit M-02. - /// Authorization failures (zero target, missing selector, not-allowlisted) revert loudly — - /// they indicate misconfiguration or a malformed report. Execution failures (an allowed call that - /// reverts) are swallowed: `CallFailed` is emitted and the report is consumed, matching - /// Chainlink Automation's fire-and-forget semantics where the next trigger re-evaluates - /// eligibility. - /// Staleness: when the block-number monotonicity check is enabled for the pair (see - /// {setBlockNumberCheck}), a report whose block number is older than the last accepted one - /// is skipped — `StaleReportSkipped` is emitted and the report is consumed without executing - /// the target call or reverting. - /// Gas-guard: when `s_consumerGasLimit[target][selector]` is non-zero, the function - /// reverts with `InsufficientGas` before the target call if available gas is below - /// `gasLimit + gasLimit / 63 + GAS_OVERHEAD`. The `gasLimit / 63` term accounts for - /// the EIP-150 (63/64) rule: a CALL forwards at most 63/64 of available gas, so - /// without this buffer a high gas limit (above ~441,000) would cause the target to - /// receive less than configured. This ensures a low-gas delivery is recorded as failed - /// by the forwarder and can be retried, preventing griefing attacks. Each - /// (target, selector) pair has its own configurable limit. - /// Pause guard: when the contract is paused (see {pause}), this function short-circuits - /// before any decoding or execution, and its behavior depends on the mode the owner - /// selected at pause time. In retryable mode it reverts with `EnforcedPause` (the revert - /// propagates through `onReport`, so the forwarder records the transmission as failed and - /// it resumes after {unpause}). In non-retryable mode it emits `ReportSkippedWhilePaused` - /// and returns, consuming (dropping) the report so it is not redelivered. - function _processReport(bytes calldata report) internal override { - if (paused()) { - if (s_retryableWhilePaused) { - revert EnforcedPause(); - } - emit ReportSkippedWhilePaused(); - return; - } - // Read the inherited permission fields directly (warm SLOADs). ReceiverTemplate.onReport - // already loaded all four slots before dispatching here, so these reads cost ~100 gas - // each — far cheaper than a self-STATICCALL to the external getters. - if (s_forwarderAddress == address(0)) { - revert InvalidForwarderAddress(); - } - if (s_expectedWorkflowId == bytes32(0) && - (s_expectedAuthor == address(0) || s_expectedWorkflowName == bytes10(0))) { - revert WorkflowIdentityNotConfigured(); - } - - (address target, uint256 reportBlockNumber, bytes memory data) = - abi.decode(report, (address, uint256, bytes)); + (address target, uint256 reportBlockNumber, bytes memory data) = abi.decode(report, (address, uint256, bytes)); - if (target == address(0)) { - revert InvalidTargetAddress(); - } - if (data.length < 4) { - revert MissingSelector(); - } + if (target == address(0)) { + revert InvalidTargetAddress(); + } + if (data.length < 4) { + revert MissingSelector(); + } - // Read the leading 4-byte selector from the in-memory `data`. Safe: length >= 4 is - // checked above, and a 32-byte mload assigned to bytes4 keeps the high (first) 4 bytes. - bytes4 selector; - assembly { - selector := mload(add(data, 0x20)) - } - if (!s_callAllowed[target][selector]) { - revert CallNotAllowed(target, selector); - } + // Read the leading 4-byte selector from the in-memory `data`. Safe: length >= 4 is + // checked above, and a 32-byte mload assigned to bytes4 keeps the high (first) 4 bytes. + bytes4 selector; + assembly { + selector := mload(add(data, 0x20)) + } + if (!s_callAllowed[target][selector]) { + revert CallNotAllowed(target, selector); + } - // Opt-in staleness protection: reject reports older than the last accepted one for this pair. - // CLA-parity comparison (>=): a report at the same block is still accepted. The stored block - // is updated before the gas guard, but an InsufficientGas revert rolls it back so a retry at - // the same block stays valid. - if (s_blockNumberCheckEnabled[target][selector]) { - uint256 lastReportBlock = s_lastReportBlock[target][selector]; - if (reportBlockNumber < lastReportBlock) { - emit StaleReportSkipped(target, selector, reportBlockNumber, lastReportBlock); - return; - } - s_lastReportBlock[target][selector] = reportBlockNumber; - } + // Opt-in staleness protection: reject reports older than the last accepted one for this pair. + // CLA-parity comparison (>=): a report at the same block is still accepted. The stored block + // is updated before the gas guard, but an InsufficientGas revert rolls it back so a retry at + // the same block stays valid. + if (s_blockNumberCheckEnabled[target][selector]) { + uint256 lastReportBlock = s_lastReportBlock[target][selector]; + if (reportBlockNumber < lastReportBlock) { + emit StaleReportSkipped(target, selector, reportBlockNumber, lastReportBlock); + return; + } + s_lastReportBlock[target][selector] = reportBlockNumber; + } - uint256 consumerGasLimit = s_consumerGasLimit[target][selector]; - bool success; - bytes memory returnData; - if (consumerGasLimit > 0) { - // consumerGasLimit / 63 compensates for EIP-150: a CALL forwards at most - // 63/64 of available gas. Without this term, limits above ~441,000 - // (63 × GAS_OVERHEAD, ~441,000) would cause the target to receive less than requested. - uint256 required = consumerGasLimit + consumerGasLimit / 63 + GAS_OVERHEAD; - if (gasleft() < required) { - revert InsufficientGas(gasleft(), required); - } - (success, returnData) = target.call{gas: consumerGasLimit}(data); - } else { - (success, returnData) = target.call(data); - } + uint256 consumerGasLimit = s_consumerGasLimit[target][selector]; + bool success; + bytes memory returnData; + if (consumerGasLimit > 0) { + // consumerGasLimit / 63 compensates for EIP-150: a CALL forwards at most + // 63/64 of available gas. Without this term, limits above ~441,000 + // (63 × GAS_OVERHEAD, ~441,000) would cause the target to receive less than requested. + uint256 required = consumerGasLimit + consumerGasLimit / 63 + GAS_OVERHEAD; + if (gasleft() < required) { + revert InsufficientGas(gasleft(), required); + } + (success, returnData) = target.call{gas: consumerGasLimit}(data); + } else { + (success, returnData) = target.call(data); + } - if (success) { - emit CallExecuted(target, selector, returnData); - } else { - emit CallFailed(target, selector, returnData); - } + if (success) { + emit CallExecuted(target, selector, returnData); + } else { + emit CallFailed(target, selector, returnData); } -} \ No newline at end of file + } +} diff --git a/contracts/src/v0.8/automation/IERC165.sol b/contracts/src/v0.8/automation/IERC165.sol index 47aca8d133..5d28886a8b 100644 --- a/contracts/src/v0.8/automation/IERC165.sol +++ b/contracts/src/v0.8/automation/IERC165.sol @@ -24,4 +24,4 @@ interface IERC165 { function supportsInterface( bytes4 interfaceId ) external view returns (bool); -} \ No newline at end of file +} diff --git a/contracts/src/v0.8/automation/IReceiver.sol b/contracts/src/v0.8/automation/IReceiver.sol index 8ead884408..762eb071c6 100644 --- a/contracts/src/v0.8/automation/IReceiver.sol +++ b/contracts/src/v0.8/automation/IReceiver.sol @@ -11,8 +11,5 @@ interface IReceiver is IERC165 { /// limit. The receiver is responsible for discarding stale reports. /// @param metadata Report's metadata. /// @param report Workflow report. - function onReport( - bytes calldata metadata, - bytes calldata report - ) external; -} \ No newline at end of file + function onReport(bytes calldata metadata, bytes calldata report) external; +} diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index 240e021aec..1f863f01f8 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -78,10 +78,7 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { /// @inheritdoc IReceiver /// @dev Performs optional validation checks based on which permission fields are set - function onReport( - bytes calldata metadata, - bytes calldata report - ) external override { + function onReport(bytes calldata metadata, bytes calldata report) external override { // Security Check 1: Verify caller is the trusted Chainlink Forwarder (if configured) if (s_forwarderAddress != address(0) && msg.sender != s_forwarderAddress) { revert InvalidSender(msg.sender, s_forwarderAddress); @@ -242,4 +239,4 @@ abstract contract ReceiverTemplate is IReceiver, Ownable { ) public view virtual override returns (bool) { return interfaceId == type(IReceiver).interfaceId || interfaceId == type(IERC165).interfaceId; } -} \ No newline at end of file +} From 83bc30b8c5835f2408df3296ec86cfea79f376ac Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Wed, 8 Jul 2026 14:58:54 -0300 Subject: [PATCH 15/29] Fix solidity lint --- contracts/src/v0.8/automation/AutomationReceiver.sol | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation/AutomationReceiver.sol index 72f5619e59..b1e0bf0582 100644 --- a/contracts/src/v0.8/automation/AutomationReceiver.sol +++ b/contracts/src/v0.8/automation/AutomationReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.24; -import "./ReceiverTemplate.sol"; +import {ReceiverTemplate} from "./ReceiverTemplate.sol"; import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; /** @@ -384,8 +384,10 @@ contract AutomationReceiver is ReceiverTemplate, Pausable { if (gasleft() < required) { revert InsufficientGas(gasleft(), required); } + // solhint-disable-next-line avoid-low-level-calls (success, returnData) = target.call{gas: consumerGasLimit}(data); } else { + // solhint-disable-next-line avoid-low-level-calls (success, returnData) = target.call(data); } From 83bd1037c98c2d94d12ee8f67e3d61bc5f231c13 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Thu, 9 Jul 2026 22:58:50 -0300 Subject: [PATCH 16/29] Fix Rens comments --- contracts/src/v0.8/automation/IERC165.sol | 27 ------------------- contracts/src/v0.8/automation/IReceiver.sol | 2 +- .../src/v0.8/automation/ReceiverTemplate.sol | 2 +- 3 files changed, 2 insertions(+), 29 deletions(-) delete mode 100644 contracts/src/v0.8/automation/IERC165.sol diff --git a/contracts/src/v0.8/automation/IERC165.sol b/contracts/src/v0.8/automation/IERC165.sol deleted file mode 100644 index 5d28886a8b..0000000000 --- a/contracts/src/v0.8/automation/IERC165.sol +++ /dev/null @@ -1,27 +0,0 @@ -// SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v5.4.0) (utils/introspection/IERC165.sol) - -pragma solidity >=0.4.16; - -/** - * @dev Interface of the ERC-165 standard, as defined in the - * https://eips.ethereum.org/EIPS/eip-165[ERC]. - * - * 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[ERC 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); -} diff --git a/contracts/src/v0.8/automation/IReceiver.sol b/contracts/src/v0.8/automation/IReceiver.sol index 762eb071c6..95edaf4abe 100644 --- a/contracts/src/v0.8/automation/IReceiver.sol +++ b/contracts/src/v0.8/automation/IReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import {IERC165} from "./IERC165.sol"; +import {IERC165} from "@openzeppelin/contracts@5.1.0/utils/introspection/IERC165.sol"; /// @title IReceiver - receives keystone reports /// @notice Implementations must support the IReceiver interface through ERC165. diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation/ReceiverTemplate.sol index 1f863f01f8..be1d68e5ce 100644 --- a/contracts/src/v0.8/automation/ReceiverTemplate.sol +++ b/contracts/src/v0.8/automation/ReceiverTemplate.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.24; -import {IERC165} from "./IERC165.sol"; import {IReceiver} from "./IReceiver.sol"; import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; +import {IERC165} from "@openzeppelin/contracts@5.1.0/utils/introspection/IERC165.sol"; /// @title ReceiverTemplate - Abstract receiver with optional permission controls /// @notice Provides flexible, updatable security checks for receiving workflow reports From 0a3dd9884ca02335bddb047cc9cc6a62d4441446 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Fri, 10 Jul 2026 13:04:05 -0300 Subject: [PATCH 17/29] Add automation-cre folder --- .github/CODEOWNERS | 9 ++++-- .github/workflows/solidity-foundry.yml | 3 ++ contracts/GNUmakefile | 2 +- contracts/foundry.toml | 7 +++++ .../native_solc_compile_all_automation | 1 - .../native_solc_compile_all_automation_cre | 28 +++++++++++++++++++ .../AutomationReceiver.sol | 0 .../IReceiver.sol | 0 .../ReceiverTemplate.sol | 0 .../generate_automation_cre/wrap.go | 20 +++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 2 +- gethwrappers/go_generate.go | 1 + gethwrappers/go_generate_automation.go | 1 - gethwrappers/go_generate_automation_cre.go | 3 ++ 14 files changed, 70 insertions(+), 7 deletions(-) create mode 100755 contracts/scripts/native_solc_compile_all_automation_cre rename contracts/src/v0.8/{automation => automation-cre}/AutomationReceiver.sol (100%) rename contracts/src/v0.8/{automation => automation-cre}/IReceiver.sol (100%) rename contracts/src/v0.8/{automation => automation-cre}/ReceiverTemplate.sol (100%) create mode 100644 gethwrappers/generation/generate_automation_cre/wrap.go create mode 100644 gethwrappers/go_generate_automation_cre.go diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 87f114638f..1e6601eb21 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -21,17 +21,19 @@ /contracts/**/*keeper* @smartcontractkit/dev-services /contracts/**/*upkeep* @smartcontractkit/dev-services /contracts/**/*automation* @smartcontractkit/dev-services +/contracts/**/*automation-cre* @smartcontractkit/cld-vault /contracts/**/*functions* @smartcontractkit/dev-services /contracts/**/*l2ep* @smartcontractkit/data-growth /contracts/**/*llo-feeds* @smartcontractkit/data-streams-engineers /contracts/**/*operatorforwarder* @smartcontractkit/data-feeds-engineers /contracts/**/*data-feeds* @smartcontractkit/data-feeds-engineers /contracts/**/*vrf* @smartcontractkit/dev-services -/contracts/**/*keystone* @smartcontractkit/cre-onchain -/contracts/**/*workflow* @smartcontractkit/cre-onchain +/contracts/**/*keystone* @smartcontractkit/cld-vault +/contracts/**/*workflow* @smartcontractkit/cld-vault /contracts/**/*payments* @smartcontractkit/payments /contracts/src/v0.8/automation @smartcontractkit/dev-services +/contracts/src/v0.8/automation-cre @smartcontractkit/cld-vault /contracts/src/v0.8/functions @smartcontractkit/dev-services /contracts/src/v0.8/l2ep @smartcontractkit/data-growth /contracts/src/v0.8/llo-feeds @smartcontractkit/data-streams-engineers @@ -41,7 +43,7 @@ /contracts/src/v0.8/shared @smartcontractkit/core-solidity /contracts/src/v0.8/vrf @smartcontractkit/dev-services /contracts/src/v0.8/payments @smartcontractkit/payments -/contracts/cre @smartcontractkit/cre-onchain +/contracts/cre @smartcontractkit/cld-vault /gethwrappers @smartcontractkit/core-solidity /gethwrappers/functions @smartcontractkit/dev-services @@ -56,6 +58,7 @@ /gethwrappers/keeper @smartcontractkit/dev-services /gethwrappers/upkeep @smartcontractkit/dev-services /gethwrappers/automation @smartcontractkit/dev-services +/gethwrappers/automation-cre @smartcontractkit/cld-vault /gethwrappers/l2ep @smartcontractkit/data-growth /gethwrappers/vrf @smartcontractkit/dev-services diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index e143e1c368..07f4a941be 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -24,6 +24,7 @@ jobs: cat < matrix.json [ { "name": "automation", "setup": { "run-coverage": false, "min-coverage": 98.5, "run-gas-snapshot": false }}, + { "name": "automation-cre", "setup": { "run-coverage": true, "min-coverage": 98.5, "run-gas-snapshot": true }}, { "name": "dev", "setup": { "run-coverage": true, "extra-coverage-params": "--ir-minimum", "min-coverage": 72.8, "run-gas-snapshot": true, "subfolder": "/cre" }}, { "name": "v1", "setup": { "run-coverage": false, "extra-coverage-params": "--ir-minimum --no-match-coverage='(.*v1/test.*)|(.*v2/test.*)'", "min-coverage": 72.8, "run-gas-snapshot": true, "subfolder": "/cre" }}, { "name": "v2", "setup": { "run-coverage": true, "extra-coverage-params": "--ir-minimum --no-match-coverage='(.*v1/test.*)|(.*v2/test.*)'", "min-coverage": 93, "run-gas-snapshot": true, "subfolder": "/cre" }}, @@ -81,6 +82,8 @@ jobs: - modified|added: 'contracts/src/v0.8/**/!(tests|mocks)/!(*.t).sol' automation: - 'contracts/src/v0.8/automation/**/*.sol' + automation-cre: + - 'contracts/src/v0.8/automation-cre/**/*.sol' functions: - 'contracts/src/v0.8/functions/**/*.sol' cre: diff --git a/contracts/GNUmakefile b/contracts/GNUmakefile index 537fa78dff..cd83e11ce9 100644 --- a/contracts/GNUmakefile +++ b/contracts/GNUmakefile @@ -1,6 +1,6 @@ # ALL_FOUNDRY_PRODUCTS contains a list of all products that have a foundry # profile defined and use the Foundry snapshots. -ALL_FOUNDRY_PRODUCTS = functions keystone l2ep llo-feeds operatorforwarder payments shared workflow data-feeds +ALL_FOUNDRY_PRODUCTS = automation-cre functions keystone l2ep llo-feeds operatorforwarder payments shared workflow data-feeds # To make a snapshot for a specific product, either set the `FOUNDRY_PROFILE` env var # or call the target with `FOUNDRY_PROFILE=product` diff --git a/contracts/foundry.toml b/contracts/foundry.toml index a283d1e635..8c0ebfa475 100644 --- a/contracts/foundry.toml +++ b/contracts/foundry.toml @@ -79,6 +79,13 @@ optimizer_runs = 1_000_000 src = 'src/v0.8/automation' deny_warnings = false +[profile.automation-cre] +solc_version = '0.8.24' +src = 'src/v0.8/automation-cre' +test = 'src/v0.8/automation-cre/test' +optimizer_runs = 1_000_000 +evm_version = 'paris' + [profile.l2ep] solc_version = '0.8.24' optimizer_runs = 1_000_000 diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation index 71c6bbf75e..369ef54e0b 100755 --- a/contracts/scripts/native_solc_compile_all_automation +++ b/contracts/scripts/native_solc_compile_all_automation @@ -63,4 +63,3 @@ compileContract automation-compile-23 upkeeps/EthBalanceMonitor compileContract automation-compile-23 v2_3/AutomationUtils2_3 compileContract automation-compile-23 interfaces/v2_3/IAutomationRegistryMaster2_3 compileContract automation-compile-23 testhelpers/MockETHUSDAggregator -compileContract automation-compile-24 AutomationReceiver diff --git a/contracts/scripts/native_solc_compile_all_automation_cre b/contracts/scripts/native_solc_compile_all_automation_cre new file mode 100755 index 0000000000..287d7696a3 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_automation_cre @@ -0,0 +1,28 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Automation CRE contracts... │" +echo " └──────────────────────────────────────────────┘" + +PROJECT="automation-cre" +CONTRACTS_DIR="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../ && pwd -P )" + +compileContract() { + local contract=$(basename "$2") + echo "Compiling" "$contract" + + local command + command="env FOUNDRY_PROFILE=$1 forge build $CONTRACTS_DIR/src/v0.8/$PROJECT/$2.sol \ + --root $CONTRACTS_DIR \ + --extra-output-files bin abi \ + -o $CONTRACTS_DIR/solc/$PROJECT/$contract" + $command + + # Copy the generated abi files to a single folder + mkdir -p "$CONTRACTS_DIR"/abi/v0.8/"$PROJECT" + cp "$CONTRACTS_DIR"/solc/$PROJECT/"$contract"/"$contract".sol/"$contract".abi.json "$CONTRACTS_DIR"/abi/v0.8/"$PROJECT"/"$contract".abi.json +} + +compileContract automation-compile-24 AutomationReceiver diff --git a/contracts/src/v0.8/automation/AutomationReceiver.sol b/contracts/src/v0.8/automation-cre/AutomationReceiver.sol similarity index 100% rename from contracts/src/v0.8/automation/AutomationReceiver.sol rename to contracts/src/v0.8/automation-cre/AutomationReceiver.sol diff --git a/contracts/src/v0.8/automation/IReceiver.sol b/contracts/src/v0.8/automation-cre/IReceiver.sol similarity index 100% rename from contracts/src/v0.8/automation/IReceiver.sol rename to contracts/src/v0.8/automation-cre/IReceiver.sol diff --git a/contracts/src/v0.8/automation/ReceiverTemplate.sol b/contracts/src/v0.8/automation-cre/ReceiverTemplate.sol similarity index 100% rename from contracts/src/v0.8/automation/ReceiverTemplate.sol rename to contracts/src/v0.8/automation-cre/ReceiverTemplate.sol diff --git a/gethwrappers/generation/generate_automation_cre/wrap.go b/gethwrappers/generation/generate_automation_cre/wrap.go new file mode 100644 index 0000000000..92a8a2441d --- /dev/null +++ b/gethwrappers/generation/generate_automation_cre/wrap.go @@ -0,0 +1,20 @@ +package main + +import ( + "os" + + "github.com/smartcontractkit/chainlink-evm/gethwrappers/generation/generate/genwrapper" +) + +func main() { + rootDir := "../contracts/solc/" + project := "automation-cre" + inputClassName := os.Args[1] + outputClassName := os.Args[2] + pkgName := os.Args[3] + + abiPath := rootDir + project + "/" + inputClassName + "/" + inputClassName + ".sol/" + inputClassName + ".abi.json" + binPath := rootDir + project + "/" + inputClassName + "/" + inputClassName + ".sol/" + inputClassName + ".bin" + + genwrapper.GenWrapper(abiPath, binPath, outputClassName, pkgName, "") +} diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 21058cfad8..2ecdb4319a 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 -automation_receiver: ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin c8d03ed089c8a4734d4cb7146852b3b323177dc0d47f7f3c23d436af3c3a062b +automation_receiver: ../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin c8d03ed089c8a4734d4cb7146852b3b323177dc0d47f7f3c23d436af3c3a062b automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef diff --git a/gethwrappers/go_generate.go b/gethwrappers/go_generate.go index 36f842ca1b..29d0a39518 100644 --- a/gethwrappers/go_generate.go +++ b/gethwrappers/go_generate.go @@ -6,6 +6,7 @@ package gethwrappers //go:generate ../contracts/scripts/native_solc_compile_all //go:generate go generate go_generate_automation.go +//go:generate go generate go_generate_automation_cre.go //go:generate go generate go_generate_vrf.go //go:generate go generate ./functions diff --git a/gethwrappers/go_generate_automation.go b/gethwrappers/go_generate_automation.go index 006f736c49..4b87b5fb52 100644 --- a/gethwrappers/go_generate_automation.go +++ b/gethwrappers/go_generate_automation.go @@ -24,7 +24,6 @@ package gethwrappers //go:generate go run ./generation/wrap.go automation IChainModule i_chain_module //go:generate go run ./generation/wrap.go automation IAutomationV21PlusCommon i_automation_v21_plus_common //go:generate go run ./generation/wrap.go automation MockETHUSDAggregator mock_ethusd_aggregator_wrapper -//go:generate go run ./generation/generate_automation/wrap.go AutomationReceiver AutomationReceiver automation_receiver //go:generate go run ./generation/wrap.go automation ILogAutomation i_log_automation //go:generate go run ./generation/wrap.go automation AutomationForwarderLogic automation_forwarder_logic diff --git a/gethwrappers/go_generate_automation_cre.go b/gethwrappers/go_generate_automation_cre.go new file mode 100644 index 0000000000..2c306c1c82 --- /dev/null +++ b/gethwrappers/go_generate_automation_cre.go @@ -0,0 +1,3 @@ +package gethwrappers + +//go:generate go run ./generation/generate_automation_cre/wrap.go AutomationReceiver AutomationReceiver automation_receiver From bbc8b2c080666daad76adae2c7e1df35c6a7cc4c Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 08:56:12 -0300 Subject: [PATCH 18/29] Include automation-cre on go_generate file --- gethwrappers/go_generate.go | 1 + 1 file changed, 1 insertion(+) diff --git a/gethwrappers/go_generate.go b/gethwrappers/go_generate.go index 29d0a39518..51d1eef91b 100644 --- a/gethwrappers/go_generate.go +++ b/gethwrappers/go_generate.go @@ -4,6 +4,7 @@ package gethwrappers // Make sure solidity compiler artifacts are up-to-date. Only output stdout on failure. //go:generate ../contracts/scripts/native_solc_compile_all +//go:generate ../contracts/scripts/native_solc_compile_all_automation_cre //go:generate go generate go_generate_automation.go //go:generate go generate go_generate_automation_cre.go From 3c6711abd9dac7c64164793a3a2bd82d64a808d1 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:06:06 -0300 Subject: [PATCH 19/29] Add AutomationReceiver tests --- .../AutomationReceiver.t.sol | 678 ++++++++++++++++++ 1 file changed, 678 insertions(+) create mode 100644 contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol diff --git a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol new file mode 100644 index 0000000000..f469032212 --- /dev/null +++ b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol @@ -0,0 +1,678 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.24; + +import {AutomationReceiver} from "../../AutomationReceiver.sol"; +import {ReceiverTemplate} from "../../ReceiverTemplate.sol"; +import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; +import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; + +interface Vm { + function prank(address msgSender) external; + + function expectRevert(bytes4 revertData) external; + + function expectRevert(bytes calldata revertData) external; + + /// @dev Marks `target` cold, as if it had never been accessed in the current transaction. + /// Used to simulate production delivery, where setCallAllowed ran in an earlier + /// transaction and the target account is therefore cold at delivery time — unlike a + /// same-transaction Foundry test, which would otherwise leave it warm. + function cool(address target) external; +} + +/// @dev Minimal Automation-style target. `performUpkeep` records the last performData and +/// can be toggled to revert, to exercise the execution-failure path. +contract MockUpkeep { + bool public shouldRevert; + uint256 public performCount; + bytes public lastPerformData; + + function setShouldRevert(bool value) external { + shouldRevert = value; + } + + function performUpkeep(bytes calldata performData) external { + if (shouldRevert) { + revert("upkeep failed"); + } + performCount++; + lastPerformData = performData; + } +} + +/// @dev Burns a fixed amount of gas on every call so we can test the insufficient-gas guard. +contract MockGasHog { + uint256 public callCount; + + function performUpkeep(bytes calldata) external { + callCount++; + } +} + +/// @dev Records the gas remaining at the start of performUpkeep. +contract MockGasRecorder { + uint256 public gasOnEntry; + + function performUpkeep(bytes calldata) external { + gasOnEntry = gasleft(); + } +} + +/// @dev Worst case for GAS_OVERHEAD: consumes every unit of forwarded gas and reverts (OOG). +contract MockGasBurner { + function performUpkeep(bytes calldata) external pure { + // solhint-disable-next-line no-empty-blocks + while (true) {} + } +} + +contract AutomationReceiverTest { + Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); + + address private constant FORWARDER = address(uint160(1)); + address private constant ATTACKER = address(uint160(3)); + bytes4 private constant PERFORM_SELECTOR = bytes4(keccak256("performUpkeep(bytes)")); + + bytes32 private constant WORKFLOW_ID = bytes32(uint256(42)); + address private constant WORKFLOW_OWNER = address(uint160(5)); + + uint256 private constant GAS_OVERHEAD = 7000; + + AutomationReceiver private receiver; + MockUpkeep private target; + MockGasHog private gasHog; + MockGasRecorder private gasRecorder; + MockGasBurner private gasBurner; + + constructor() { + receiver = new AutomationReceiver(FORWARDER); + receiver.setExpectedWorkflowId(WORKFLOW_ID); + receiver.setExpectedAuthor(WORKFLOW_OWNER); + target = new MockUpkeep(); + gasHog = new MockGasHog(); + gasRecorder = new MockGasRecorder(); + gasBurner = new MockGasBurner(); + } + + // ─── helpers ──────────────────────────────────────────────── + function _performCall(bytes memory performData) private pure returns (bytes memory) { + return abi.encodeWithSignature("performUpkeep(bytes)", performData); + } + + function _report(address tgt, bytes memory callData) private pure returns (bytes memory) { + return abi.encode(tgt, uint256(0), callData); + } + + function _reportAtBlock( + address tgt, + uint256 blockNumber, + bytes memory callData + ) private pure returns (bytes memory) { + return abi.encode(tgt, blockNumber, callData); + } + + function _metadata(bytes32 wfId, address wfOwner) private pure returns (bytes memory) { + return abi.encodePacked(wfId, bytes10(0), wfOwner); + } + + function _deliver(bytes memory report) private { + vm.prank(FORWARDER); + receiver.onReport(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + } + + function _deliverOutcome(address tgt, uint256 gasAmount, bytes memory report) private returns (uint8) { + vm.cool(tgt); + vm.prank(FORWARDER); + try receiver.onReport{gas: gasAmount}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report) { + return 0; + } catch (bytes memory data) { + bytes4 sel; + if (data.length >= 4) { + assembly { + sel := mload(add(data, 32)) + } + } + return sel == AutomationReceiver.InsufficientGas.selector ? 1 : 2; + } + } + + // ─── inbound auth ──────────────────────────────────────────── + function test_onReport_RevertWhen_InvalidSender() external { + bytes memory report = _report(address(target), _performCall(hex"01")); + + vm.expectRevert(abi.encodeWithSelector(_invalidSenderSelector(), ATTACKER, FORWARDER)); + vm.prank(ATTACKER); + receiver.onReport(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + } + + // ─── forwarder-zero guard ──────────────────────────────────── + function test_onReport_RevertWhen_ForwarderIsZero() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setForwarderAddress(address(0)); + + vm.expectRevert(ReceiverTemplate.InvalidForwarderAddress.selector); + receiver.onReport(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), _report(address(target), _performCall(hex"01"))); + } + + // ─── workflow identity guard ───────────────────────────────── + function test_onReport_WorkflowIdAloneSuffices() external { + AutomationReceiver freshReceiver = new AutomationReceiver(FORWARDER); + freshReceiver.setExpectedWorkflowId(WORKFLOW_ID); + freshReceiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + vm.prank(FORWARDER); + freshReceiver.onReport(_metadata(WORKFLOW_ID, address(0)), _report(address(target), _performCall(hex"01"))); + + _assertEq(target.performCount(), 1); + } + + function test_onReport_OwnerAndNameSufficeWithoutWorkflowId() external { + AutomationReceiver freshReceiver = new AutomationReceiver(FORWARDER); + freshReceiver.setExpectedAuthor(WORKFLOW_OWNER); + freshReceiver.setExpectedWorkflowName("my-workflow"); + freshReceiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + bytes10 wfName = freshReceiver.getExpectedWorkflowName(); + + vm.prank(FORWARDER); + freshReceiver.onReport( + abi.encodePacked(bytes32(0), wfName, WORKFLOW_OWNER), + _report(address(target), _performCall(hex"01")) + ); + + _assertEq(target.performCount(), 1); + } + + function test_onReport_RevertWhen_OwnerSetButNameMissing() external { + AutomationReceiver freshReceiver = new AutomationReceiver(FORWARDER); + freshReceiver.setExpectedAuthor(WORKFLOW_OWNER); + freshReceiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + vm.expectRevert(AutomationReceiver.WorkflowIdentityNotConfigured.selector); + vm.prank(FORWARDER); + freshReceiver.onReport(_metadata(bytes32(0), WORKFLOW_OWNER), _report(address(target), _performCall(hex"01"))); + } + + function test_onReport_RevertWhen_NoIdentityConfigured() external { + AutomationReceiver freshReceiver = new AutomationReceiver(FORWARDER); + freshReceiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + vm.expectRevert(AutomationReceiver.WorkflowIdentityNotConfigured.selector); + vm.prank(FORWARDER); + freshReceiver.onReport(_metadata(bytes32(0), address(0)), _report(address(target), _performCall(hex"01"))); + } + + function test_onReport_CombinedIdentityAccepted() external { + AutomationReceiver freshReceiver = new AutomationReceiver(FORWARDER); + freshReceiver.setExpectedWorkflowId(WORKFLOW_ID); + freshReceiver.setExpectedAuthor(WORKFLOW_OWNER); + freshReceiver.setExpectedWorkflowName("my-workflow"); + freshReceiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + bytes10 wfName = freshReceiver.getExpectedWorkflowName(); + vm.prank(FORWARDER); + freshReceiver.onReport( + abi.encodePacked(WORKFLOW_ID, wfName, WORKFLOW_OWNER), + _report(address(target), _performCall(hex"01")) + ); + + _assertEq(target.performCount(), 1); + } + + // ─── outbound allowlist ───────────────────────────────────── + function test_onReport_RevertWhen_CallNotAllowed() external { + bytes memory report = _report(address(target), _performCall(hex"01")); + + vm.expectRevert( + abi.encodeWithSelector(AutomationReceiver.CallNotAllowed.selector, address(target), PERFORM_SELECTOR) + ); + _deliver(report); + } + + function test_onReport_AllowedCallExecutes() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + bytes memory performData = hex"deadbeef"; + _deliver(_report(address(target), _performCall(performData))); + + _assertEq(target.performCount(), 1); + _assertEq(keccak256(target.lastPerformData()), keccak256(performData)); + } + + function test_onReport_RevertWhen_CallRevoked() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, false); + + vm.expectRevert( + abi.encodeWithSelector(AutomationReceiver.CallNotAllowed.selector, address(target), PERFORM_SELECTOR) + ); + _deliver(_report(address(target), _performCall(hex"01"))); + } + + function test_onReport_FailingCallDoesNotRevert() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + target.setShouldRevert(true); + + _deliver(_report(address(target), _performCall(hex"01"))); + + _assertEq(target.performCount(), 0); + } + + // ─── malformed reports ────────────────────────────────────── + function test_onReport_RevertWhen_ZeroTarget() external { + vm.expectRevert(AutomationReceiver.InvalidTargetAddress.selector); + _deliver(_report(address(0), _performCall(hex"01"))); + } + + function test_onReport_RevertWhen_MissingSelector() external { + vm.expectRevert(AutomationReceiver.MissingSelector.selector); + _deliver(_report(address(target), hex"010203")); + } + + // ─── allowlist administration ─────────────────────────────── + function test_setCallAllowed_RevertWhen_NotOwner() external { + vm.expectRevert(abi.encodeWithSelector(Ownable.OwnableUnauthorizedAccount.selector, ATTACKER)); + vm.prank(ATTACKER); + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + } + + function test_setCallAllowed_RevertWhen_ZeroTarget() external { + vm.expectRevert(AutomationReceiver.InvalidTargetAddress.selector); + receiver.setCallAllowed(address(0), PERFORM_SELECTOR, true); + } + + function test_setCallAllowed_RevertWhen_CodelessTarget() external { + address eoa = address(uint160(99)); + vm.expectRevert(abi.encodeWithSelector(AutomationReceiver.TargetHasNoCode.selector, eoa)); + receiver.setCallAllowed(eoa, PERFORM_SELECTOR, true); + } + + function test_setCallAllowed_RevocationSkipsCodeCheck() external { + address eoa = address(uint160(99)); + receiver.setCallAllowed(eoa, PERFORM_SELECTOR, false); + _assertFalse(receiver.isCallAllowed(eoa, PERFORM_SELECTOR)); + } + + function test_isCallAllowed_ReflectsState() external { + _assertFalse(receiver.isCallAllowed(address(target), PERFORM_SELECTOR)); + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + _assertTrue(receiver.isCallAllowed(address(target), PERFORM_SELECTOR)); + } + + // ─── emergency pause ──────────────────────────────────────── + function test_pause_RevertWhen_NotOwner() external { + vm.expectRevert(abi.encodeWithSelector(Ownable.OwnableUnauthorizedAccount.selector, ATTACKER)); + vm.prank(ATTACKER); + receiver.pause(true); + } + + function test_unpause_RevertWhen_NotOwner() external { + receiver.pause(true); + vm.expectRevert(abi.encodeWithSelector(Ownable.OwnableUnauthorizedAccount.selector, ATTACKER)); + vm.prank(ATTACKER); + receiver.unpause(); + } + + function test_onReport_RevertWhen_PausedRetryable() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.pause(true); + + vm.expectRevert(Pausable.EnforcedPause.selector); + _deliver(_report(address(target), _performCall(hex"01"))); + + _assertEq(target.performCount(), 0); + } + + function test_onReport_PausedNonRetryableConsumesReport() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.pause(false); + + _deliver(_report(address(target), _performCall(hex"01"))); + + _assertEq(target.performCount(), 0); + } + + function test_unpause_ResumesDelivery() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + receiver.pause(true); + vm.expectRevert(Pausable.EnforcedPause.selector); + _deliver(_report(address(target), _performCall(hex"01"))); + + receiver.unpause(); + _deliver(_report(address(target), _performCall(hex"01"))); + + _assertEq(target.performCount(), 1); + } + + function test_paused_ReflectsState() external { + _assertFalse(receiver.paused()); + receiver.pause(true); + _assertTrue(receiver.paused()); + receiver.unpause(); + _assertFalse(receiver.paused()); + } + + function test_retryableWhilePaused_ReflectsMode() external { + receiver.pause(true); + _assertTrue(receiver.retryableWhilePaused()); + receiver.unpause(); + + receiver.pause(false); + _assertFalse(receiver.retryableWhilePaused()); + } + + function test_pause_RevertWhen_AlreadyPaused() external { + receiver.pause(true); + vm.expectRevert(Pausable.EnforcedPause.selector); + receiver.pause(true); + } + + function test_unpause_RevertWhen_NotPaused() external { + vm.expectRevert(Pausable.ExpectedPause.selector); + receiver.unpause(); + } + + // ─── consumer gas limit administration ───────────────────── + function test_setConsumerGasLimit_RevertWhen_NotOwner() external { + vm.expectRevert(abi.encodeWithSelector(Ownable.OwnableUnauthorizedAccount.selector, ATTACKER)); + vm.prank(ATTACKER); + receiver.setConsumerGasLimit(address(gasHog), PERFORM_SELECTOR, 500_000); + } + + function test_setConsumerGasLimit_RevertWhen_ZeroTarget() external { + vm.expectRevert(AutomationReceiver.InvalidTargetAddress.selector); + receiver.setConsumerGasLimit(address(0), PERFORM_SELECTOR, 100_000); + } + + function test_setConsumerGasLimit_SetAndGet() external { + _assertEq(receiver.getConsumerGasLimit(address(target), PERFORM_SELECTOR), 0); + + receiver.setConsumerGasLimit(address(target), PERFORM_SELECTOR, 300_000); + _assertEq(receiver.getConsumerGasLimit(address(target), PERFORM_SELECTOR), 300_000); + + receiver.setConsumerGasLimit(address(target), PERFORM_SELECTOR, 0); + _assertEq(receiver.getConsumerGasLimit(address(target), PERFORM_SELECTOR), 0); + } + + function test_setConsumerGasLimit_IsPerPair() external { + receiver.setConsumerGasLimit(address(gasHog), PERFORM_SELECTOR, 200_000); + + _assertEq(receiver.getConsumerGasLimit(address(gasHog), PERFORM_SELECTOR), 200_000); + _assertEq(receiver.getConsumerGasLimit(address(target), PERFORM_SELECTOR), 0); + _assertEq(receiver.getConsumerGasLimit(address(gasHog), bytes4(keccak256("otherFn()"))), 0); + } + + // ─── gas guard ────────────────────────────────────────────── + function test_onReport_RevertWhen_InsufficientGas() external { + receiver.setCallAllowed(address(gasHog), PERFORM_SELECTOR, true); + uint256 limit = 200_000; + receiver.setConsumerGasLimit(address(gasHog), PERFORM_SELECTOR, limit); + + bytes memory report = _report(address(gasHog), _performCall(hex"")); + bool reverted; + vm.prank(FORWARDER); + try receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD - 1}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report) { + reverted = false; + } catch (bytes memory data) { + bytes4 sel; + assembly { + sel := mload(add(data, 32)) + } + if (sel != AutomationReceiver.InsufficientGas.selector) revert("wrong revert selector"); + reverted = true; + } + _assertTrue(reverted); + } + + function test_onReport_SufficientGasWithLimitSucceeds() external { + receiver.setCallAllowed(address(gasHog), PERFORM_SELECTOR, true); + uint256 limit = 50_000; + receiver.setConsumerGasLimit(address(gasHog), PERFORM_SELECTOR, limit); + + bytes memory report = _report(address(gasHog), _performCall(hex"")); + vm.prank(FORWARDER); + receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD + 50_000}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + + _assertEq(gasHog.callCount(), 1); + } + + function test_onReport_GasLimitZeroPreservesUnboundedBehavior() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + target.setShouldRevert(true); + + _deliver(_report(address(target), _performCall(hex"01"))); + _assertEq(target.performCount(), 0); + } + + // ─── EIP-150 (63/64 rule) ──────────────────────────────────── + function test_onReport_RequiredIncludesEIP150Buffer() external { + receiver.setCallAllowed(address(gasHog), PERFORM_SELECTOR, true); + uint256 limit = 200_000; + receiver.setConsumerGasLimit(address(gasHog), PERFORM_SELECTOR, limit); + + bytes memory report = _report(address(gasHog), _performCall(hex"")); + bool reverted; + uint256 emittedRequired; + vm.prank(FORWARDER); + try receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD - 1}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report) { + reverted = false; + } catch (bytes memory errData) { + bytes4 sel; + assembly { + sel := mload(add(errData, 32)) + } + if (sel != AutomationReceiver.InsufficientGas.selector) revert("wrong revert selector"); + assembly { + emittedRequired := mload(add(errData, 68)) + } + reverted = true; + } + _assertTrue(reverted); + _assertEq(emittedRequired, limit + limit / 63 + GAS_OVERHEAD); + } + + function test_onReport_EIP150TermEnsuresFullGasForwardedAtHighLimit() external { + receiver.setCallAllowed(address(gasRecorder), PERFORM_SELECTOR, true); + uint256 limit = 1_000_000; + receiver.setConsumerGasLimit(address(gasRecorder), PERFORM_SELECTOR, limit); + + bytes memory report = _report(address(gasRecorder), _performCall(hex"")); + vm.prank(FORWARDER); + receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD + 60_000}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + + uint256 gasReceived = gasRecorder.gasOnEntry(); + _assertTrue(gasReceived >= limit - 500); + _assertTrue(gasReceived <= limit); + } + + // ─── GAS_OVERHEAD accuracy ────────────────────────────────── + function test_onReport_GasOverheadCorrectlyCoversNoOpConsumer() external { + receiver.setCallAllowed(address(gasRecorder), PERFORM_SELECTOR, true); + uint256 limit = 30_000; + receiver.setConsumerGasLimit(address(gasRecorder), PERFORM_SELECTOR, limit); + + bytes memory report = _report(address(gasRecorder), _performCall(hex"")); + vm.cool(address(gasRecorder)); + vm.prank(FORWARDER); + receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD + 60_000}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + + uint256 gasReceived = gasRecorder.gasOnEntry(); + _assertTrue(gasReceived >= limit - 500); + _assertTrue(gasReceived <= limit); + } + + function test_onReport_GasOverheadCoversWorstCaseGasBurningConsumer() external { + receiver.setCallAllowed(address(gasBurner), PERFORM_SELECTOR, true); + uint256 limit = 1_000; + receiver.setConsumerGasLimit(address(gasBurner), PERFORM_SELECTOR, limit); + bytes memory report = _report(address(gasBurner), _performCall(hex"")); + + uint256 lo = 0; + uint256 hi = 500_000; + _assertEq(_deliverOutcome(address(gasBurner), hi, report), 0); + + while (hi - lo > 1) { + uint256 mid = (lo + hi) / 2; + if (_deliverOutcome(address(gasBurner), mid, report) == 0) { + hi = mid; + } else { + lo = mid; + } + } + + _assertEq(_deliverOutcome(address(gasBurner), lo, report), 1); + } + + // ─── block-number monotonicity ─────────────────────────────── + function test_onReport_BlockNumberCheckDisabledAllowsOutOfOrder() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + + _deliver(_reportAtBlock(address(target), 100, _performCall(hex"01"))); + _deliver(_reportAtBlock(address(target), 50, _performCall(hex"01"))); + + _assertEq(target.performCount(), 2); + } + + function test_onReport_BlockNumberCheckWithExplicitFloor() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 100); + + _deliver(_reportAtBlock(address(target), 99, _performCall(hex"01"))); + _assertEq(target.performCount(), 0); + + _deliver(_reportAtBlock(address(target), 100, _performCall(hex"01"))); + _assertEq(target.performCount(), 1); + + _deliver(_reportAtBlock(address(target), 101, _performCall(hex"01"))); + _assertEq(target.performCount(), 2); + + _deliver(_reportAtBlock(address(target), 100, _performCall(hex"01"))); + _assertEq(target.performCount(), 2); + } + + function test_onReport_BlockNumberCheckEqualBlockAccepted() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 100); + + _deliver(_reportAtBlock(address(target), 100, _performCall(hex"01"))); + _deliver(_reportAtBlock(address(target), 100, _performCall(hex"01"))); + + _assertEq(target.performCount(), 2); + } + + function test_onReport_BlockNumberCheckSnapshotUsesCurrentBlock() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 0); + + (bool enabled, uint256 floor) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertTrue(enabled); + _assertEq(floor, block.number); + + if (block.number > 0) { + _deliver(_reportAtBlock(address(target), block.number - 1, _performCall(hex"01"))); + _assertEq(target.performCount(), 0); + } + + _deliver(_reportAtBlock(address(target), block.number, _performCall(hex"01"))); + _assertEq(target.performCount(), 1); + } + + function test_getBlockNumberCheck_ReflectsState() external { + (bool enabled, uint256 last) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertFalse(enabled); + _assertEq(last, 0); + + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 500); + (enabled, last) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertTrue(enabled); + _assertEq(last, 500); + + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + _deliver(_reportAtBlock(address(target), 600, _performCall(hex"01"))); + (, last) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertEq(last, 600); + + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, false, 0); + (enabled, last) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertFalse(enabled); + _assertEq(last, 0); + } + + function test_setBlockNumberCheck_IsPerPair() external { + receiver.setBlockNumberCheck(address(gasHog), PERFORM_SELECTOR, true, 300); + + (bool enabledHog, uint256 lastHog) = receiver.getBlockNumberCheck(address(gasHog), PERFORM_SELECTOR); + _assertTrue(enabledHog); + _assertEq(lastHog, 300); + + (bool enabledTarget, uint256 lastTarget) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertFalse(enabledTarget); + _assertEq(lastTarget, 0); + } + + function test_setBlockNumberCheck_RevertWhen_NotOwner() external { + vm.expectRevert(abi.encodeWithSelector(Ownable.OwnableUnauthorizedAccount.selector, ATTACKER)); + vm.prank(ATTACKER); + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 0); + } + + function test_setBlockNumberCheck_RevertWhen_ZeroTarget() external { + vm.expectRevert(AutomationReceiver.InvalidTargetAddress.selector); + receiver.setBlockNumberCheck(address(0), PERFORM_SELECTOR, true, 0); + } + + function test_onReport_InsufficientGasDoesNotAdvanceBlockNumber() external { + receiver.setCallAllowed(address(target), PERFORM_SELECTOR, true); + receiver.setBlockNumberCheck(address(target), PERFORM_SELECTOR, true, 100); + uint256 limit = 200_000; + receiver.setConsumerGasLimit(address(target), PERFORM_SELECTOR, limit); + + bytes memory report = _reportAtBlock(address(target), 100, _performCall(hex"01")); + + bool reverted; + vm.prank(FORWARDER); + try receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD - 1}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report) { + reverted = false; + } catch (bytes memory data) { + bytes4 sel; + assembly { + sel := mload(add(data, 32)) + } + if (sel != AutomationReceiver.InsufficientGas.selector) revert("wrong revert selector"); + reverted = true; + } + _assertTrue(reverted); + + (, uint256 lastBlock) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertEq(lastBlock, 100); + _assertEq(target.performCount(), 0); + + vm.prank(FORWARDER); + receiver.onReport{gas: limit + limit / 63 + GAS_OVERHEAD + 100_000}(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); + _assertEq(target.performCount(), 1); + (, lastBlock) = receiver.getBlockNumberCheck(address(target), PERFORM_SELECTOR); + _assertEq(lastBlock, 100); + } + + // ─── tiny assertion helpers (no forge-std dependency) ─────── + function _invalidSenderSelector() private pure returns (bytes4) { + return bytes4(keccak256("InvalidSender(address,address)")); + } + + function _assertEq(uint256 actual, uint256 expected) private pure { + if (actual != expected) revert("uint mismatch"); + } + + function _assertEq(bytes32 actual, bytes32 expected) private pure { + if (actual != expected) revert("bytes32 mismatch"); + } + + function _assertTrue(bool value) private pure { + if (!value) revert("expected true"); + } + + function _assertFalse(bool value) private pure { + if (value) revert("expected false"); + } +} From b1094225d02ab0f7af0d798cf10c44c207509234 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:08:55 -0300 Subject: [PATCH 20/29] Format test file and add cre-gas file --- .../gas-snapshots/automation-cre.gas-snapshot | 26 ++++++++ .../AutomationReceiver.t.sol | 66 ++++++++++++------- 2 files changed, 69 insertions(+), 23 deletions(-) create mode 100644 contracts/gas-snapshots/automation-cre.gas-snapshot diff --git a/contracts/gas-snapshots/automation-cre.gas-snapshot b/contracts/gas-snapshots/automation-cre.gas-snapshot new file mode 100644 index 0000000000..84b5e985e1 --- /dev/null +++ b/contracts/gas-snapshots/automation-cre.gas-snapshot @@ -0,0 +1,26 @@ +AutomationReceiverTest:test_getBlockNumberCheck_ReflectsState() (gas: 129244) +AutomationReceiverTest:test_isCallAllowed_ReflectsState() (gas: 39646) +AutomationReceiverTest:test_onReport_AllowedCallExecutes() (gas: 111948) +AutomationReceiverTest:test_onReport_BlockNumberCheckDisabledAllowsOutOfOrder() (gas: 121535) +AutomationReceiverTest:test_onReport_BlockNumberCheckEqualBlockAccepted() (gas: 168696) +AutomationReceiverTest:test_onReport_BlockNumberCheckSnapshotUsesCurrentBlock() (gas: 168596) +AutomationReceiverTest:test_onReport_BlockNumberCheckWithExplicitFloor() (gas: 190163) +AutomationReceiverTest:test_onReport_CombinedIdentityAccepted() (gas: 2091079) +AutomationReceiverTest:test_onReport_EIP150TermEnsuresFullGasForwardedAtHighLimit() (gas: 109007) +AutomationReceiverTest:test_onReport_FailingCallDoesNotRevert() (gas: 89373) +AutomationReceiverTest:test_onReport_GasLimitZeroPreservesUnboundedBehavior() (gas: 89376) +AutomationReceiverTest:test_onReport_GasOverheadCorrectlyCoversNoOpConsumer() (gas: 109465) +AutomationReceiverTest:test_onReport_GasOverheadCoversWorstCaseGasBurningConsumer() (gas: 277744) +AutomationReceiverTest:test_onReport_InsufficientGasDoesNotAdvanceBlockNumber() (gas: 200315) +AutomationReceiverTest:test_onReport_OwnerAndNameSufficeWithoutWorkflowId() (gas: 2068988) +AutomationReceiverTest:test_onReport_PausedNonRetryableConsumesReport() (gas: 81360) +AutomationReceiverTest:test_onReport_RequiredIncludesEIP150Buffer() (gas: 83267) +AutomationReceiverTest:test_onReport_SufficientGasWithLimitSucceeds() (gas: 108949) +AutomationReceiverTest:test_onReport_WorkflowIdAloneSuffices() (gas: 2036307) +AutomationReceiverTest:test_paused_ReflectsState() (gas: 42403) +AutomationReceiverTest:test_retryableWhilePaused_ReflectsMode() (gas: 59730) +AutomationReceiverTest:test_setBlockNumberCheck_IsPerPair() (gas: 66425) +AutomationReceiverTest:test_setCallAllowed_RevocationSkipsCodeCheck() (gas: 13542) +AutomationReceiverTest:test_setConsumerGasLimit_IsPerPair() (gas: 44609) +AutomationReceiverTest:test_setConsumerGasLimit_SetAndGet() (gas: 29639) +AutomationReceiverTest:test_unpause_ResumesDelivery() (gas: 148797) \ No newline at end of file diff --git a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol index f469032212..7ac2c39d52 100644 --- a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol +++ b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol @@ -7,17 +7,25 @@ import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; interface Vm { - function prank(address msgSender) external; + function prank( + address msgSender + ) external; - function expectRevert(bytes4 revertData) external; + function expectRevert( + bytes4 revertData + ) external; - function expectRevert(bytes calldata revertData) external; + function expectRevert( + bytes calldata revertData + ) external; /// @dev Marks `target` cold, as if it had never been accessed in the current transaction. /// Used to simulate production delivery, where setCallAllowed ran in an earlier /// transaction and the target account is therefore cold at delivery time — unlike a /// same-transaction Foundry test, which would otherwise leave it warm. - function cool(address target) external; + function cool( + address target + ) external; } /// @dev Minimal Automation-style target. `performUpkeep` records the last performData and @@ -27,11 +35,15 @@ contract MockUpkeep { uint256 public performCount; bytes public lastPerformData; - function setShouldRevert(bool value) external { + function setShouldRevert( + bool value + ) external { shouldRevert = value; } - function performUpkeep(bytes calldata performData) external { + function performUpkeep( + bytes calldata performData + ) external { if (shouldRevert) { revert("upkeep failed"); } @@ -44,7 +56,9 @@ contract MockUpkeep { contract MockGasHog { uint256 public callCount; - function performUpkeep(bytes calldata) external { + function performUpkeep( + bytes calldata + ) external { callCount++; } } @@ -53,14 +67,18 @@ contract MockGasHog { contract MockGasRecorder { uint256 public gasOnEntry; - function performUpkeep(bytes calldata) external { + function performUpkeep( + bytes calldata + ) external { gasOnEntry = gasleft(); } } /// @dev Worst case for GAS_OVERHEAD: consumes every unit of forwarded gas and reverts (OOG). contract MockGasBurner { - function performUpkeep(bytes calldata) external pure { + function performUpkeep( + bytes calldata + ) external pure { // solhint-disable-next-line no-empty-blocks while (true) {} } @@ -95,7 +113,9 @@ contract AutomationReceiverTest { } // ─── helpers ──────────────────────────────────────────────── - function _performCall(bytes memory performData) private pure returns (bytes memory) { + function _performCall( + bytes memory performData + ) private pure returns (bytes memory) { return abi.encodeWithSignature("performUpkeep(bytes)", performData); } @@ -103,11 +123,7 @@ contract AutomationReceiverTest { return abi.encode(tgt, uint256(0), callData); } - function _reportAtBlock( - address tgt, - uint256 blockNumber, - bytes memory callData - ) private pure returns (bytes memory) { + function _reportAtBlock(address tgt, uint256 blockNumber, bytes memory callData) private pure returns (bytes memory) { return abi.encode(tgt, blockNumber, callData); } @@ -115,7 +131,9 @@ contract AutomationReceiverTest { return abi.encodePacked(wfId, bytes10(0), wfOwner); } - function _deliver(bytes memory report) private { + function _deliver( + bytes memory report + ) private { vm.prank(FORWARDER); receiver.onReport(_metadata(WORKFLOW_ID, WORKFLOW_OWNER), report); } @@ -176,8 +194,7 @@ contract AutomationReceiverTest { vm.prank(FORWARDER); freshReceiver.onReport( - abi.encodePacked(bytes32(0), wfName, WORKFLOW_OWNER), - _report(address(target), _performCall(hex"01")) + abi.encodePacked(bytes32(0), wfName, WORKFLOW_OWNER), _report(address(target), _performCall(hex"01")) ); _assertEq(target.performCount(), 1); @@ -212,8 +229,7 @@ contract AutomationReceiverTest { bytes10 wfName = freshReceiver.getExpectedWorkflowName(); vm.prank(FORWARDER); freshReceiver.onReport( - abi.encodePacked(WORKFLOW_ID, wfName, WORKFLOW_OWNER), - _report(address(target), _performCall(hex"01")) + abi.encodePacked(WORKFLOW_ID, wfName, WORKFLOW_OWNER), _report(address(target), _performCall(hex"01")) ); _assertEq(target.performCount(), 1); @@ -504,7 +520,7 @@ contract AutomationReceiverTest { function test_onReport_GasOverheadCoversWorstCaseGasBurningConsumer() external { receiver.setCallAllowed(address(gasBurner), PERFORM_SELECTOR, true); - uint256 limit = 1_000; + uint256 limit = 1000; receiver.setConsumerGasLimit(address(gasBurner), PERFORM_SELECTOR, limit); bytes memory report = _report(address(gasBurner), _performCall(hex"")); @@ -668,11 +684,15 @@ contract AutomationReceiverTest { if (actual != expected) revert("bytes32 mismatch"); } - function _assertTrue(bool value) private pure { + function _assertTrue( + bool value + ) private pure { if (!value) revert("expected true"); } - function _assertFalse(bool value) private pure { + function _assertFalse( + bool value + ) private pure { if (value) revert("expected false"); } } From a79c1bac2f3c848bf63900197ae964c38820b2d6 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:14:54 -0300 Subject: [PATCH 21/29] Add tests for ReceiverTemplate --- .../gas-snapshots/automation-cre.gas-snapshot | 6 +- .../AutomationReceiver.t.sol | 2 + .../ReceiverTemplate/ReceiverTemplate.t.sol | 137 ++++++++++++++++++ 3 files changed, 144 insertions(+), 1 deletion(-) create mode 100644 contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol diff --git a/contracts/gas-snapshots/automation-cre.gas-snapshot b/contracts/gas-snapshots/automation-cre.gas-snapshot index 84b5e985e1..0bf91a8783 100644 --- a/contracts/gas-snapshots/automation-cre.gas-snapshot +++ b/contracts/gas-snapshots/automation-cre.gas-snapshot @@ -23,4 +23,8 @@ AutomationReceiverTest:test_setBlockNumberCheck_IsPerPair() (gas: 66425) AutomationReceiverTest:test_setCallAllowed_RevocationSkipsCodeCheck() (gas: 13542) AutomationReceiverTest:test_setConsumerGasLimit_IsPerPair() (gas: 44609) AutomationReceiverTest:test_setConsumerGasLimit_SetAndGet() (gas: 29639) -AutomationReceiverTest:test_unpause_ResumesDelivery() (gas: 148797) \ No newline at end of file +AutomationReceiverTest:test_unpause_ResumesDelivery() (gas: 148797) +ReceiverTemplateTest:test_onReport_AcceptsWhenMetadataMatches() (gas: 1169308) +ReceiverTemplateTest:test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() (gas: 1072363) +ReceiverTemplateTest:test_setExpectedWorkflowName_CanBeSetWithoutAuthor() (gas: 1067209) +ReceiverTemplateTest:test_setForwarderAddress_ZeroSucceedsAtTemplateLevel() (gas: 998852) \ No newline at end of file diff --git a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol index 7ac2c39d52..72e8d57304 100644 --- a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol +++ b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol @@ -1,6 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.24; +// solhint-disable gas-custom-errors,interface-starts-with-i,chainlink-solidity/all-caps-constant-storage-variables,chainlink-solidity/prefix-storage-variables-with-s-underscore + import {AutomationReceiver} from "../../AutomationReceiver.sol"; import {ReceiverTemplate} from "../../ReceiverTemplate.sol"; import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; diff --git a/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol new file mode 100644 index 0000000000..aab9797fb1 --- /dev/null +++ b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol @@ -0,0 +1,137 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.24; + +// solhint-disable +// gas-custom-errors,interface-starts-with-i,chainlink-solidity/all-caps-constant-storage-variables,chainlink-solidity/prefix-storage-variables-with-s-underscore + +import {ReceiverTemplate} from "../../ReceiverTemplate.sol"; + +interface Vm { + function prank( + address msgSender + ) external; + + function expectRevert( + bytes4 revertData + ) external; + + function expectRevert( + bytes calldata revertData + ) external; +} + +contract MockReceiver is ReceiverTemplate { + uint256 public reportCount; + bytes32 public lastReportHash; + + constructor( + address forwarder + ) ReceiverTemplate(forwarder) {} + + function _processReport( + bytes calldata report + ) internal override { + reportCount++; + lastReportHash = keccak256(report); + } +} + +contract ReceiverTemplateTest { + Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code"))))); + + address private constant FORWARDER = address(uint160(1)); + address private constant AUTHOR = address(uint160(2)); + address private constant ATTACKER = address(uint160(3)); + bytes32 private constant WORKFLOW_ID = bytes32(uint256(0x1234)); + + function test_constructor_RevertWhen_ZeroForwarder() external { + vm.expectRevert(ReceiverTemplate.InvalidForwarderAddress.selector); + new MockReceiver(address(0)); + } + + function test_onReport_RevertWhen_InvalidSender() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + + vm.expectRevert(abi.encodeWithSelector(ReceiverTemplate.InvalidSender.selector, ATTACKER, FORWARDER)); + vm.prank(ATTACKER); + receiver.onReport("", "report"); + } + + /// @dev setForwarderAddress(address(0)) is permitted at the ReceiverTemplate level — + /// it emits a SecurityWarning but does not revert. Concrete contracts such as + /// AutomationReceiver close this gap inside _processReport. + function test_setForwarderAddress_ZeroSucceedsAtTemplateLevel() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setForwarderAddress(address(0)); + } + + /// @dev setExpectedWorkflowName succeeds even without an author set — the dependency is + /// enforced lazily inside onReport (WorkflowNameRequiresAuthorValidation). + function test_setExpectedWorkflowName_CanBeSetWithoutAuthor() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedWorkflowName("game-resolution"); + } + + /// @dev Clearing the author while a workflow name is set does not revert on the setter itself. + function test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedAuthor(AUTHOR); + receiver.setExpectedWorkflowName("game-resolution"); + receiver.setExpectedAuthor(address(0)); + } + + function test_onReport_AcceptsWhenMetadataMatches() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedAuthor(AUTHOR); + receiver.setExpectedWorkflowId(WORKFLOW_ID); + receiver.setExpectedWorkflowName("game-resolution"); + + bytes memory metadata = abi.encodePacked(WORKFLOW_ID, _workflowName("game-resolution"), AUTHOR); + bytes memory report = abi.encode("verified report"); + + vm.prank(FORWARDER); + receiver.onReport(metadata, report); + + _assertEq(receiver.reportCount(), 1); + _assertEq(receiver.lastReportHash(), keccak256(report)); + } + + function test_onReport_RevertWhen_WrongWorkflowOwner() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedAuthor(AUTHOR); + + bytes memory metadata = abi.encodePacked(WORKFLOW_ID, _workflowName("game-resolution"), ATTACKER); + + vm.expectRevert(abi.encodeWithSelector(ReceiverTemplate.InvalidAuthor.selector, ATTACKER, AUTHOR)); + vm.prank(FORWARDER); + receiver.onReport(metadata, "report"); + } + + function _workflowName( + string memory name + ) private pure returns (bytes10) { + bytes32 hash = sha256(bytes(name)); + bytes16 hexChars = "0123456789abcdef"; + bytes memory hexString = new bytes(64); + + for (uint256 i = 0; i < 32; i++) { + hexString[i * 2] = hexChars[uint8(hash[i] >> 4)]; + hexString[i * 2 + 1] = hexChars[uint8(hash[i] & 0x0f)]; + } + + bytes memory first10 = new bytes(10); + for (uint256 i = 0; i < 10; i++) { + first10[i] = hexString[i]; + } + + return bytes10(first10); + } + + function _assertEq(uint256 actual, uint256 expected) private pure { + if (actual != expected) revert("uint mismatch"); + } + + function _assertEq(bytes32 actual, bytes32 expected) private pure { + if (actual != expected) revert("bytes32 mismatch"); + } +} From 68c4b5c33005c053d4a1ea7788d91a2febbb4d63 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:24:06 -0300 Subject: [PATCH 22/29] Cover 98% coverage tests for cre-automation contracts --- contracts/foundry.toml | 1 + .../gas-snapshots/automation-cre.gas-snapshot | 62 ++++++++++-------- .../AutomationReceiver.t.sol | 29 ++++++++- .../ReceiverTemplate/ReceiverTemplate.t.sol | 65 +++++++++++++++++++ 4 files changed, 128 insertions(+), 29 deletions(-) diff --git a/contracts/foundry.toml b/contracts/foundry.toml index 8c0ebfa475..81b38ec1cf 100644 --- a/contracts/foundry.toml +++ b/contracts/foundry.toml @@ -85,6 +85,7 @@ src = 'src/v0.8/automation-cre' test = 'src/v0.8/automation-cre/test' optimizer_runs = 1_000_000 evm_version = 'paris' +deny_warnings = false [profile.l2ep] solc_version = '0.8.24' diff --git a/contracts/gas-snapshots/automation-cre.gas-snapshot b/contracts/gas-snapshots/automation-cre.gas-snapshot index 0bf91a8783..475cbcc41e 100644 --- a/contracts/gas-snapshots/automation-cre.gas-snapshot +++ b/contracts/gas-snapshots/automation-cre.gas-snapshot @@ -1,30 +1,36 @@ -AutomationReceiverTest:test_getBlockNumberCheck_ReflectsState() (gas: 129244) -AutomationReceiverTest:test_isCallAllowed_ReflectsState() (gas: 39646) -AutomationReceiverTest:test_onReport_AllowedCallExecutes() (gas: 111948) -AutomationReceiverTest:test_onReport_BlockNumberCheckDisabledAllowsOutOfOrder() (gas: 121535) -AutomationReceiverTest:test_onReport_BlockNumberCheckEqualBlockAccepted() (gas: 168696) -AutomationReceiverTest:test_onReport_BlockNumberCheckSnapshotUsesCurrentBlock() (gas: 168596) -AutomationReceiverTest:test_onReport_BlockNumberCheckWithExplicitFloor() (gas: 190163) +AutomationReceiverTest:test_getBlockNumberCheck_ReflectsState() (gas: 129208) +AutomationReceiverTest:test_getters_ReflectState() (gas: 13457) +AutomationReceiverTest:test_isCallAllowed_ReflectsState() (gas: 39680) +AutomationReceiverTest:test_onReport_AllowedCallExecutes() (gas: 111992) +AutomationReceiverTest:test_onReport_BlockNumberCheckDisabledAllowsOutOfOrder() (gas: 121493) +AutomationReceiverTest:test_onReport_BlockNumberCheckEqualBlockAccepted() (gas: 168653) +AutomationReceiverTest:test_onReport_BlockNumberCheckSnapshotUsesCurrentBlock() (gas: 168640) +AutomationReceiverTest:test_onReport_BlockNumberCheckWithExplicitFloor() (gas: 190185) AutomationReceiverTest:test_onReport_CombinedIdentityAccepted() (gas: 2091079) -AutomationReceiverTest:test_onReport_EIP150TermEnsuresFullGasForwardedAtHighLimit() (gas: 109007) -AutomationReceiverTest:test_onReport_FailingCallDoesNotRevert() (gas: 89373) -AutomationReceiverTest:test_onReport_GasLimitZeroPreservesUnboundedBehavior() (gas: 89376) -AutomationReceiverTest:test_onReport_GasOverheadCorrectlyCoversNoOpConsumer() (gas: 109465) +AutomationReceiverTest:test_onReport_EIP150TermEnsuresFullGasForwardedAtHighLimit() (gas: 109029) +AutomationReceiverTest:test_onReport_FailingCallDoesNotRevert() (gas: 89395) +AutomationReceiverTest:test_onReport_GasLimitZeroPreservesUnboundedBehavior() (gas: 89398) +AutomationReceiverTest:test_onReport_GasOverheadCorrectlyCoversNoOpConsumer() (gas: 109487) AutomationReceiverTest:test_onReport_GasOverheadCoversWorstCaseGasBurningConsumer() (gas: 277744) -AutomationReceiverTest:test_onReport_InsufficientGasDoesNotAdvanceBlockNumber() (gas: 200315) -AutomationReceiverTest:test_onReport_OwnerAndNameSufficeWithoutWorkflowId() (gas: 2068988) -AutomationReceiverTest:test_onReport_PausedNonRetryableConsumesReport() (gas: 81360) -AutomationReceiverTest:test_onReport_RequiredIncludesEIP150Buffer() (gas: 83267) -AutomationReceiverTest:test_onReport_SufficientGasWithLimitSucceeds() (gas: 108949) -AutomationReceiverTest:test_onReport_WorkflowIdAloneSuffices() (gas: 2036307) -AutomationReceiverTest:test_paused_ReflectsState() (gas: 42403) -AutomationReceiverTest:test_retryableWhilePaused_ReflectsMode() (gas: 59730) -AutomationReceiverTest:test_setBlockNumberCheck_IsPerPair() (gas: 66425) -AutomationReceiverTest:test_setCallAllowed_RevocationSkipsCodeCheck() (gas: 13542) -AutomationReceiverTest:test_setConsumerGasLimit_IsPerPair() (gas: 44609) -AutomationReceiverTest:test_setConsumerGasLimit_SetAndGet() (gas: 29639) -AutomationReceiverTest:test_unpause_ResumesDelivery() (gas: 148797) -ReceiverTemplateTest:test_onReport_AcceptsWhenMetadataMatches() (gas: 1169308) -ReceiverTemplateTest:test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() (gas: 1072363) -ReceiverTemplateTest:test_setExpectedWorkflowName_CanBeSetWithoutAuthor() (gas: 1067209) -ReceiverTemplateTest:test_setForwarderAddress_ZeroSucceedsAtTemplateLevel() (gas: 998852) \ No newline at end of file +AutomationReceiverTest:test_onReport_InsufficientGasDoesNotAdvanceBlockNumber() (gas: 200337) +AutomationReceiverTest:test_onReport_OwnerAndNameSufficeWithoutWorkflowId() (gas: 2068944) +AutomationReceiverTest:test_onReport_PausedNonRetryableConsumesReport() (gas: 81382) +AutomationReceiverTest:test_onReport_RequiredIncludesEIP150Buffer() (gas: 83289) +AutomationReceiverTest:test_onReport_SufficientGasWithLimitSucceeds() (gas: 108971) +AutomationReceiverTest:test_onReport_WorkflowIdAloneSuffices() (gas: 2036262) +AutomationReceiverTest:test_paused_ReflectsState() (gas: 42368) +AutomationReceiverTest:test_retryableWhilePaused_ReflectsMode() (gas: 59695) +AutomationReceiverTest:test_setBlockNumberCheck_IsPerPair() (gas: 66447) +AutomationReceiverTest:test_setCallAllowed_RevocationSkipsCodeCheck() (gas: 13520) +AutomationReceiverTest:test_setConsumerGasLimit_IsPerPair() (gas: 44564) +AutomationReceiverTest:test_setConsumerGasLimit_SetAndGet() (gas: 29656) +AutomationReceiverTest:test_supportsInterface_ERC165() (gas: 5785) +AutomationReceiverTest:test_supportsInterface_IReceiver() (gas: 5714) +AutomationReceiverTest:test_supportsInterface_ReturnsFalseForUnknown() (gas: 5742) +AutomationReceiverTest:test_unpause_ResumesDelivery() (gas: 148819) +ReceiverTemplateTest:test_getters_ReflectState() (gas: 1096546) +ReceiverTemplateTest:test_onReport_AcceptsWhenMetadataMatches() (gas: 1169353) +ReceiverTemplateTest:test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() (gas: 1072364) +ReceiverTemplateTest:test_setExpectedWorkflowName_CanBeSetWithoutAuthor() (gas: 1067232) +ReceiverTemplateTest:test_setForwarderAddress_ZeroSucceedsAtTemplateLevel() (gas: 998853) +ReceiverTemplateTest:test_supportsInterface() (gas: 1015005) \ No newline at end of file diff --git a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol index 72e8d57304..274d6113d1 100644 --- a/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol +++ b/contracts/src/v0.8/automation-cre/test/AutomationReceiver/AutomationReceiver.t.sol @@ -1,9 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.24; -// solhint-disable gas-custom-errors,interface-starts-with-i,chainlink-solidity/all-caps-constant-storage-variables,chainlink-solidity/prefix-storage-variables-with-s-underscore +// solhint-disable +// gas-custom-errors,interface-starts-with-i,chainlink-solidity/all-caps-constant-storage-variables,chainlink-solidity/prefix-storage-variables-with-s-underscore import {AutomationReceiver} from "../../AutomationReceiver.sol"; + +import {IReceiver} from "../../IReceiver.sol"; import {ReceiverTemplate} from "../../ReceiverTemplate.sol"; import {Ownable} from "@openzeppelin/contracts@5.1.0/access/Ownable.sol"; import {Pausable} from "@openzeppelin/contracts@5.1.0/utils/Pausable.sol"; @@ -673,6 +676,26 @@ contract AutomationReceiverTest { _assertEq(lastBlock, 100); } + // ─── supportsInterface ─────────────────────────────────────── + function test_supportsInterface_ERC165() external { + _assertTrue(receiver.supportsInterface(0x01ffc9a7)); + } + + function test_supportsInterface_IReceiver() external { + _assertTrue(receiver.supportsInterface(type(IReceiver).interfaceId)); + } + + function test_supportsInterface_ReturnsFalseForUnknown() external { + _assertFalse(receiver.supportsInterface(0xdeadbeef)); + } + + // ─── getters ──────────────────────────────────────────────── + function test_getters_ReflectState() external { + _assertEq(receiver.getForwarderAddress(), FORWARDER); + _assertEq(receiver.getExpectedAuthor(), WORKFLOW_OWNER); + _assertEq(receiver.getExpectedWorkflowId(), WORKFLOW_ID); + } + // ─── tiny assertion helpers (no forge-std dependency) ─────── function _invalidSenderSelector() private pure returns (bytes4) { return bytes4(keccak256("InvalidSender(address,address)")); @@ -686,6 +709,10 @@ contract AutomationReceiverTest { if (actual != expected) revert("bytes32 mismatch"); } + function _assertEq(address actual, address expected) private pure { + if (actual != expected) revert("address mismatch"); + } + function _assertTrue( bool value ) private pure { diff --git a/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol index aab9797fb1..5d992e7c52 100644 --- a/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol +++ b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol @@ -107,6 +107,61 @@ contract ReceiverTemplateTest { receiver.onReport(metadata, "report"); } + function test_onReport_RevertWhen_WrongWorkflowId() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedWorkflowId(WORKFLOW_ID); + + bytes32 wrongId = bytes32(uint256(0x9999)); + bytes memory metadata = abi.encodePacked(wrongId, _workflowName(""), AUTHOR); + + vm.expectRevert(abi.encodeWithSelector(ReceiverTemplate.InvalidWorkflowId.selector, wrongId, WORKFLOW_ID)); + vm.prank(FORWARDER); + receiver.onReport(metadata, "report"); + } + + function test_onReport_RevertWhen_WorkflowNameSetButAuthorMissing() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedWorkflowName("game-resolution"); + + bytes memory metadata = abi.encodePacked(bytes32(0), _workflowName("game-resolution"), address(0)); + + vm.expectRevert(ReceiverTemplate.WorkflowNameRequiresAuthorValidation.selector); + vm.prank(FORWARDER); + receiver.onReport(metadata, "report"); + } + + function test_onReport_RevertWhen_WrongWorkflowName() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedAuthor(AUTHOR); + receiver.setExpectedWorkflowName("game-resolution"); + + bytes10 wrongName = _workflowName("other-workflow"); + bytes memory metadata = abi.encodePacked(bytes32(0), wrongName, AUTHOR); + + vm.expectRevert( + abi.encodeWithSelector(ReceiverTemplate.InvalidWorkflowName.selector, wrongName, _workflowName("game-resolution")) + ); + vm.prank(FORWARDER); + receiver.onReport(metadata, "report"); + } + + function test_getters_ReflectState() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedAuthor(AUTHOR); + receiver.setExpectedWorkflowId(WORKFLOW_ID); + receiver.setExpectedWorkflowName("game-resolution"); + + _assertEq(receiver.getForwarderAddress(), FORWARDER); + _assertEq(receiver.getExpectedAuthor(), AUTHOR); + _assertEq(receiver.getExpectedWorkflowId(), WORKFLOW_ID); + } + + function test_supportsInterface() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + // IReceiver interfaceId + _assertTrue(receiver.supportsInterface(0x01ffc9a7)); // ERC165 + } + function _workflowName( string memory name ) private pure returns (bytes10) { @@ -134,4 +189,14 @@ contract ReceiverTemplateTest { function _assertEq(bytes32 actual, bytes32 expected) private pure { if (actual != expected) revert("bytes32 mismatch"); } + + function _assertEq(address actual, address expected) private pure { + if (actual != expected) revert("address mismatch"); + } + + function _assertTrue( + bool value + ) private pure { + if (!value) revert("expected true"); + } } From 42543f973a05b5d032fa6e561b37c9505666a7e4 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:30:47 -0300 Subject: [PATCH 23/29] Coverage 99% tests --- contracts/gas-snapshots/automation-cre.gas-snapshot | 1 + .../test/ReceiverTemplate/ReceiverTemplate.t.sol | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/contracts/gas-snapshots/automation-cre.gas-snapshot b/contracts/gas-snapshots/automation-cre.gas-snapshot index 475cbcc41e..84c3a87326 100644 --- a/contracts/gas-snapshots/automation-cre.gas-snapshot +++ b/contracts/gas-snapshots/automation-cre.gas-snapshot @@ -32,5 +32,6 @@ ReceiverTemplateTest:test_getters_ReflectState() (gas: 1096546) ReceiverTemplateTest:test_onReport_AcceptsWhenMetadataMatches() (gas: 1169353) ReceiverTemplateTest:test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() (gas: 1072364) ReceiverTemplateTest:test_setExpectedWorkflowName_CanBeSetWithoutAuthor() (gas: 1067232) +ReceiverTemplateTest:test_setExpectedWorkflowName_ClearWithEmptyString() (gas: 1051069) ReceiverTemplateTest:test_setForwarderAddress_ZeroSucceedsAtTemplateLevel() (gas: 998853) ReceiverTemplateTest:test_supportsInterface() (gas: 1015005) \ No newline at end of file diff --git a/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol index 5d992e7c52..ad8d257981 100644 --- a/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol +++ b/contracts/src/v0.8/automation-cre/test/ReceiverTemplate/ReceiverTemplate.t.sol @@ -72,6 +72,13 @@ contract ReceiverTemplateTest { receiver.setExpectedWorkflowName("game-resolution"); } + function test_setExpectedWorkflowName_ClearWithEmptyString() external { + MockReceiver receiver = new MockReceiver(FORWARDER); + receiver.setExpectedWorkflowName("game-resolution"); + receiver.setExpectedWorkflowName(""); + if (receiver.getExpectedWorkflowName() != bytes10(0)) revert("expected empty workflow name"); + } + /// @dev Clearing the author while a workflow name is set does not revert on the setter itself. function test_setExpectedAuthor_ClearingAuthorWhileNameSetDoesNotRevert() external { MockReceiver receiver = new MockReceiver(FORWARDER); From 0a4ed6ffa299578248684f5bc542b0d50aff51a0 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:52:30 -0300 Subject: [PATCH 24/29] add automation-cre to native_solc file in scripts --- contracts/scripts/native_solc_compile_all | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 45128b3fb2..0c72a423fa 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -14,6 +14,6 @@ SCRIPTPATH="$( # For each product we have a native_solc_compile_all_$product script # These scripts can be run individually, or all together with this script. # To add new CL products, simply write a native_solc_compile_all_$product script and add it to the list below. -for product in automation functions llo-feeds operatorforwarder payments shared vrf data-feeds l2ep; do +for product in automation automation-cre functions llo-feeds operatorforwarder payments shared vrf data-feeds l2ep; do $SCRIPTPATH/native_solc_compile_all_$product done From 34786ad49d4979fb4673f11dff3f9b415a1b2e1a Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 09:57:44 -0300 Subject: [PATCH 25/29] Revert codeowner changes --- .github/CODEOWNERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 1e6601eb21..13e323ca44 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -28,8 +28,8 @@ /contracts/**/*operatorforwarder* @smartcontractkit/data-feeds-engineers /contracts/**/*data-feeds* @smartcontractkit/data-feeds-engineers /contracts/**/*vrf* @smartcontractkit/dev-services -/contracts/**/*keystone* @smartcontractkit/cld-vault -/contracts/**/*workflow* @smartcontractkit/cld-vault +/contracts/**/*keystone* @smartcontractkit/cre-onchain +/contracts/**/*workflow* @smartcontractkit/cre-onchain /contracts/**/*payments* @smartcontractkit/payments /contracts/src/v0.8/automation @smartcontractkit/dev-services @@ -43,7 +43,7 @@ /contracts/src/v0.8/shared @smartcontractkit/core-solidity /contracts/src/v0.8/vrf @smartcontractkit/dev-services /contracts/src/v0.8/payments @smartcontractkit/payments -/contracts/cre @smartcontractkit/cld-vault +/contracts/cre @smartcontractkit/cre-onchain /gethwrappers @smartcontractkit/core-solidity /gethwrappers/functions @smartcontractkit/dev-services From e2b6ff87c864bbfe2f8ad5d41ea5a5c595e3df7e Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 10:03:00 -0300 Subject: [PATCH 26/29] Update automation-cre file to be used on the bash scipt --- ...ll_automation_cre => native_solc_compile_all_automation-cre} | 0 gethwrappers/go_generate.go | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename contracts/scripts/{native_solc_compile_all_automation_cre => native_solc_compile_all_automation-cre} (100%) diff --git a/contracts/scripts/native_solc_compile_all_automation_cre b/contracts/scripts/native_solc_compile_all_automation-cre similarity index 100% rename from contracts/scripts/native_solc_compile_all_automation_cre rename to contracts/scripts/native_solc_compile_all_automation-cre diff --git a/gethwrappers/go_generate.go b/gethwrappers/go_generate.go index 51d1eef91b..f233249c3b 100644 --- a/gethwrappers/go_generate.go +++ b/gethwrappers/go_generate.go @@ -4,7 +4,7 @@ package gethwrappers // Make sure solidity compiler artifacts are up-to-date. Only output stdout on failure. //go:generate ../contracts/scripts/native_solc_compile_all -//go:generate ../contracts/scripts/native_solc_compile_all_automation_cre +//go:generate ../contracts/scripts/native_solc_compile_all_automation-cre //go:generate go generate go_generate_automation.go //go:generate go generate go_generate_automation_cre.go From b92720025ad543db6e4bc58f8c2ac90988e6f44c Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 11:55:10 -0300 Subject: [PATCH 27/29] Remove unnecesary lines and fix gethwrapper generator on automation-cre --- gethwrappers/automation-cre/go_generate.go | 5 +++++ .../generate_automation_cre/wrap.go | 20 ------------------- gethwrappers/go_generate.go | 3 +-- gethwrappers/go_generate_automation_cre.go | 3 --- 4 files changed, 6 insertions(+), 25 deletions(-) create mode 100644 gethwrappers/automation-cre/go_generate.go delete mode 100644 gethwrappers/generation/generate_automation_cre/wrap.go delete mode 100644 gethwrappers/go_generate_automation_cre.go diff --git a/gethwrappers/automation-cre/go_generate.go b/gethwrappers/automation-cre/go_generate.go new file mode 100644 index 0000000000..3e01738d2f --- /dev/null +++ b/gethwrappers/automation-cre/go_generate.go @@ -0,0 +1,5 @@ +// Package gethwrappers provides tools for wrapping solidity contracts with +// golang packages, using abigen. +package gethwrappers + +//go:generate go run ../wrap automation-cre AutomationReceiver automation_receiver diff --git a/gethwrappers/generation/generate_automation_cre/wrap.go b/gethwrappers/generation/generate_automation_cre/wrap.go deleted file mode 100644 index 92a8a2441d..0000000000 --- a/gethwrappers/generation/generate_automation_cre/wrap.go +++ /dev/null @@ -1,20 +0,0 @@ -package main - -import ( - "os" - - "github.com/smartcontractkit/chainlink-evm/gethwrappers/generation/generate/genwrapper" -) - -func main() { - rootDir := "../contracts/solc/" - project := "automation-cre" - inputClassName := os.Args[1] - outputClassName := os.Args[2] - pkgName := os.Args[3] - - abiPath := rootDir + project + "/" + inputClassName + "/" + inputClassName + ".sol/" + inputClassName + ".abi.json" - binPath := rootDir + project + "/" + inputClassName + "/" + inputClassName + ".sol/" + inputClassName + ".bin" - - genwrapper.GenWrapper(abiPath, binPath, outputClassName, pkgName, "") -} diff --git a/gethwrappers/go_generate.go b/gethwrappers/go_generate.go index f233249c3b..638ff31b0c 100644 --- a/gethwrappers/go_generate.go +++ b/gethwrappers/go_generate.go @@ -4,12 +4,11 @@ package gethwrappers // Make sure solidity compiler artifacts are up-to-date. Only output stdout on failure. //go:generate ../contracts/scripts/native_solc_compile_all -//go:generate ../contracts/scripts/native_solc_compile_all_automation-cre //go:generate go generate go_generate_automation.go -//go:generate go generate go_generate_automation_cre.go //go:generate go generate go_generate_vrf.go +//go:generate go generate ./automation-cre //go:generate go generate ./functions //go:generate go generate ./llo-feeds //go:generate go generate ./operatorforwarder diff --git a/gethwrappers/go_generate_automation_cre.go b/gethwrappers/go_generate_automation_cre.go deleted file mode 100644 index 2c306c1c82..0000000000 --- a/gethwrappers/go_generate_automation_cre.go +++ /dev/null @@ -1,3 +0,0 @@ -package gethwrappers - -//go:generate go run ./generation/generate_automation_cre/wrap.go AutomationReceiver AutomationReceiver automation_receiver From 7b46ff2c1a5f87334172b971bc8edfdc41993ae7 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 12:02:05 -0300 Subject: [PATCH 28/29] refactor(gethwrappers): migrate automation-cre wrapper to modern generation pattern --- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 ++ .../generated-wrapper-dependency-versions-do-not-edit.txt | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 gethwrappers/automation-cre/generation/generated-wrapper-dependency-versions-do-not-edit.txt diff --git a/gethwrappers/automation-cre/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/automation-cre/generation/generated-wrapper-dependency-versions-do-not-edit.txt new file mode 100644 index 0000000000..80ee200f49 --- /dev/null +++ b/gethwrappers/automation-cre/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -0,0 +1,2 @@ +GETH_VERSION: 1.17.3 +automation_receiver: ../../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin c8d03ed089c8a4734d4cb7146852b3b323177dc0d47f7f3c23d436af3c3a062b diff --git a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 2ecdb4319a..152cc17291 100644 --- a/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,6 @@ arbitrum_module: ../contracts/solc/automation/ArbitrumModule/ArbitrumModule.sol/ automation_compatible_utils: ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.abi.json ../contracts/solc/automation/AutomationCompatibleUtils/AutomationCompatibleUtils.sol/AutomationCompatibleUtils.bin 6054a3c82fde7e76641c8f9607a86332932d8f8f4f92216803ef245091fd7544 automation_consumer_benchmark: ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.abi.json ../contracts/solc/automation/AutomationConsumerBenchmark/AutomationConsumerBenchmark.sol/AutomationConsumerBenchmark.bin 0033c709cb99becaf375c876da93c63a27a748942e2b70d8650016f61d5e8a7c automation_forwarder_logic: ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.abi.json ../contracts/solc/automation/AutomationForwarderLogic/AutomationForwarderLogic.sol/AutomationForwarderLogic.bin 14b96065532d3d2acc5298f002954475bfdb9c6d546fc50f745a2a714ef069e4 -automation_receiver: ../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.abi.json ../contracts/solc/automation-cre/AutomationReceiver/AutomationReceiver.sol/AutomationReceiver.bin c8d03ed089c8a4734d4cb7146852b3b323177dc0d47f7f3c23d436af3c3a062b automation_registrar_wrapper2_1: ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.abi.json ../contracts/solc/automation/AutomationRegistrar2_1/AutomationRegistrar2_1.sol/AutomationRegistrar2_1.bin 618a1038a1fc2c4d5ad2122b886f4b3e71ba905fb9010f031609c617d107d5c4 automation_registrar_wrapper2_3: ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.abi.json ../contracts/solc/automation/AutomationRegistrar2_3/AutomationRegistrar2_3.sol/AutomationRegistrar2_3.bin 17387e14fc3b79f52803a76a1a614dd93cf90c31231dd1629a852538ae7ea07d automation_registry_logic_a_wrapper_2_3: ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.abi.json ../contracts/solc/automation/AutomationRegistryLogicA2_3/AutomationRegistryLogicA2_3.sol/AutomationRegistryLogicA2_3.bin 876d99619785131edff51d39b73bc15a7179b5083cf3efeb0b1a7f23a3fa5fef From 95614b90d199de7161eb9d78ddc5c15664f1dff9 Mon Sep 17 00:00:00 2001 From: bitrider23 Date: Mon, 13 Jul 2026 12:12:28 -0300 Subject: [PATCH 29/29] Move automation-cre binding file --- .../automation_receiver.go | 42 ------------------- 1 file changed, 42 deletions(-) rename gethwrappers/{generated => automation-cre/generated/latest}/automation_receiver/automation_receiver.go (98%) diff --git a/gethwrappers/generated/automation_receiver/automation_receiver.go b/gethwrappers/automation-cre/generated/latest/automation_receiver/automation_receiver.go similarity index 98% rename from gethwrappers/generated/automation_receiver/automation_receiver.go rename to gethwrappers/automation-cre/generated/latest/automation_receiver/automation_receiver.go index 540767fffb..2d98745212 100644 --- a/gethwrappers/generated/automation_receiver/automation_receiver.go +++ b/gethwrappers/automation-cre/generated/latest/automation_receiver/automation_receiver.go @@ -5,7 +5,6 @@ package automation_receiver import ( "errors" - "fmt" "math/big" "strings" @@ -15,7 +14,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/event" - "github.com/smartcontractkit/chainlink-evm/gethwrappers/generated" ) var ( @@ -2542,44 +2540,6 @@ type GetBlockNumberCheck struct { LastReportBlock *big.Int } -func (_AutomationReceiver *AutomationReceiver) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _AutomationReceiver.abi.Events["BlockNumberCheckSet"].ID: - return _AutomationReceiver.ParseBlockNumberCheckSet(log) - case _AutomationReceiver.abi.Events["CallAllowedSet"].ID: - return _AutomationReceiver.ParseCallAllowedSet(log) - case _AutomationReceiver.abi.Events["CallExecuted"].ID: - return _AutomationReceiver.ParseCallExecuted(log) - case _AutomationReceiver.abi.Events["CallFailed"].ID: - return _AutomationReceiver.ParseCallFailed(log) - case _AutomationReceiver.abi.Events["ConsumerGasLimitSet"].ID: - return _AutomationReceiver.ParseConsumerGasLimitSet(log) - case _AutomationReceiver.abi.Events["ExpectedAuthorUpdated"].ID: - return _AutomationReceiver.ParseExpectedAuthorUpdated(log) - case _AutomationReceiver.abi.Events["ExpectedWorkflowIdUpdated"].ID: - return _AutomationReceiver.ParseExpectedWorkflowIdUpdated(log) - case _AutomationReceiver.abi.Events["ExpectedWorkflowNameUpdated"].ID: - return _AutomationReceiver.ParseExpectedWorkflowNameUpdated(log) - case _AutomationReceiver.abi.Events["ForwarderAddressUpdated"].ID: - return _AutomationReceiver.ParseForwarderAddressUpdated(log) - case _AutomationReceiver.abi.Events["OwnershipTransferred"].ID: - return _AutomationReceiver.ParseOwnershipTransferred(log) - case _AutomationReceiver.abi.Events["Paused"].ID: - return _AutomationReceiver.ParsePaused(log) - case _AutomationReceiver.abi.Events["ReportSkippedWhilePaused"].ID: - return _AutomationReceiver.ParseReportSkippedWhilePaused(log) - case _AutomationReceiver.abi.Events["SecurityWarning"].ID: - return _AutomationReceiver.ParseSecurityWarning(log) - case _AutomationReceiver.abi.Events["StaleReportSkipped"].ID: - return _AutomationReceiver.ParseStaleReportSkipped(log) - case _AutomationReceiver.abi.Events["Unpaused"].ID: - return _AutomationReceiver.ParseUnpaused(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - func (AutomationReceiverBlockNumberCheckSet) Topic() common.Hash { return common.HexToHash("0xf19a6052943cc4c32e1644d475a7b4e6f517bcae63159220028f5de68d6d0364") } @@ -2783,7 +2743,5 @@ type AutomationReceiverInterface interface { ParseUnpaused(log types.Log) (*AutomationReceiverUnpaused, error) - ParseLog(log types.Log) (generated.AbigenLog, error) - Address() common.Address }