diff --git a/.changeset/twenty-pets-look.md b/.changeset/twenty-pets-look.md new file mode 100644 index 00000000000..e2b6eaace9d --- /dev/null +++ b/.changeset/twenty-pets-look.md @@ -0,0 +1,5 @@ +--- +"chainlink": patch +--- + +#internal keystone report context diff --git a/contracts/.changeset/moody-days-share.md b/contracts/.changeset/moody-days-share.md new file mode 100644 index 00000000000..6c0eb4780b4 --- /dev/null +++ b/contracts/.changeset/moody-days-share.md @@ -0,0 +1,5 @@ +--- +'@chainlink/contracts': patch +--- + +#internal stub of keystone feed consumer contract diff --git a/contracts/src/v0.8/keystone/KeystoneFeedsConsumer.sol b/contracts/src/v0.8/keystone/KeystoneFeedsConsumer.sol new file mode 100644 index 00000000000..36058d2b11a --- /dev/null +++ b/contracts/src/v0.8/keystone/KeystoneFeedsConsumer.sol @@ -0,0 +1,28 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {IReceiver} from "./interfaces/IReceiver.sol"; + +contract KeystoneFeedsConsumer is IReceiver { + event MessageReceived(bytes32 indexed workflowId, address indexed workflowOwner, uint256 nReports); + event FeedReceived(bytes32 indexed feedId, uint256 price, uint64 timestamp); + + constructor() {} + + struct FeedReport { + bytes32 FeedID; + uint256 Price; + uint64 Timestamp; + } + + function onReport(bytes32 workflowId, address workflowOwner, bytes calldata rawReport) external { + // TODO: validate sender and workflowOwner + + FeedReport[] memory feeds = abi.decode(rawReport, (FeedReport[])); + for (uint32 i = 0; i < feeds.length; i++) { + emit FeedReceived(feeds[i].FeedID, feeds[i].Price, feeds[i].Timestamp); + } + + emit MessageReceived(workflowId, workflowOwner, feeds.length); + } +} diff --git a/contracts/src/v0.8/keystone/KeystoneForwarder.sol b/contracts/src/v0.8/keystone/KeystoneForwarder.sol index e8e574cc0bc..c47896d98c9 100644 --- a/contracts/src/v0.8/keystone/KeystoneForwarder.sol +++ b/contracts/src/v0.8/keystone/KeystoneForwarder.sol @@ -130,6 +130,7 @@ contract KeystoneForwarder is IForwarder, ConfirmedOwner, TypeAndVersionInterfac function report( address receiverAddress, bytes calldata rawReport, + bytes calldata reportContext, bytes[] calldata signatures ) external nonReentrant { if (rawReport.length < REPORT_METADATA_LENGTH) { @@ -149,14 +150,14 @@ contract KeystoneForwarder is IForwarder, ConfirmedOwner, TypeAndVersionInterfac // validate signatures { - bytes32 hash = keccak256(rawReport); + bytes32 completeHash = keccak256(abi.encodePacked(keccak256(rawReport), reportContext)); address[MAX_ORACLES] memory signed; uint8 index; for (uint256 i; i < signatures.length; ++i) { // TODO: is libocr-style multiple bytes32 arrays more optimal, gas-wise? (bytes32 r, bytes32 s, uint8 v) = _splitSignature(signatures[i]); - address signer = ecrecover(hash, v, r, s); + address signer = ecrecover(completeHash, v + 27, r, s); // validate signer is trusted and signature is unique index = uint8(s_configs[donId]._positions[signer]); @@ -167,9 +168,8 @@ contract KeystoneForwarder is IForwarder, ConfirmedOwner, TypeAndVersionInterfac } } - IReceiver receiver = IReceiver(receiverAddress); bool success; - try receiver.onReport(workflowId, workflowOwner, rawReport[REPORT_METADATA_LENGTH:]) { + try IReceiver(receiverAddress).onReport(workflowId, workflowOwner, rawReport[REPORT_METADATA_LENGTH:]) { success = true; } catch { // Do nothing, success is already false diff --git a/contracts/src/v0.8/keystone/test/KeystoneForwarder_ReportTest.t.sol b/contracts/src/v0.8/keystone/test/KeystoneForwarder_ReportTest.t.sol index eecaf4fb241..bb209e4cf98 100644 --- a/contracts/src/v0.8/keystone/test/KeystoneForwarder_ReportTest.t.sol +++ b/contracts/src/v0.8/keystone/test/KeystoneForwarder_ReportTest.t.sol @@ -19,6 +19,7 @@ contract KeystoneForwarder_ReportTest is BaseTest { bytes[] internal mercuryReports = new bytes[](2); bytes internal rawReports; bytes internal report; + bytes internal reportContext = new bytes(96); uint256 internal requiredSignaturesNum = F + 1; bytes[] internal signatures = new bytes[](2); @@ -34,8 +35,11 @@ contract KeystoneForwarder_ReportTest is BaseTest { report = abi.encodePacked(workflowId, DON_ID, executionId, workflowOwner, rawReports); for (uint256 i = 0; i < requiredSignaturesNum; i++) { - (uint8 v, bytes32 r, bytes32 s) = vm.sign(s_signers[i].mockPrivateKey, keccak256(report)); - signatures[i] = bytes.concat(r, s, bytes1(v)); + (uint8 v, bytes32 r, bytes32 s) = vm.sign( + s_signers[i].mockPrivateKey, + keccak256(abi.encodePacked(keccak256(report), reportContext)) + ); + signatures[i] = bytes.concat(r, s, bytes1(v - 27)); } vm.startPrank(TRANSMITTER); @@ -52,14 +56,14 @@ contract KeystoneForwarder_ReportTest is BaseTest { ); vm.expectRevert(abi.encodeWithSelector(KeystoneForwarder.InvalidDonId.selector, invalidDONId)); - s_forwarder.report(address(s_receiver), reportWithInvalidDONId, signatures); + s_forwarder.report(address(s_receiver), reportWithInvalidDONId, reportContext, signatures); } function test_RevertWhen_ReportIsMalformed() public { bytes memory shortenedReport = abi.encode(bytes32(report)); vm.expectRevert(KeystoneForwarder.InvalidReport.selector); - s_forwarder.report(address(s_receiver), shortenedReport, signatures); + s_forwarder.report(address(s_receiver), shortenedReport, reportContext, signatures); } function test_RevertWhen_TooFewSignatures() public { @@ -68,7 +72,7 @@ contract KeystoneForwarder_ReportTest is BaseTest { vm.expectRevert( abi.encodeWithSelector(KeystoneForwarder.InvalidSignatureCount.selector, F + 1, fewerSignatures.length) ); - s_forwarder.report(address(s_receiver), report, fewerSignatures); + s_forwarder.report(address(s_receiver), report, reportContext, fewerSignatures); } function test_RevertWhen_TooManySignatures() public { @@ -77,40 +81,43 @@ contract KeystoneForwarder_ReportTest is BaseTest { vm.expectRevert( abi.encodeWithSelector(KeystoneForwarder.InvalidSignatureCount.selector, F + 1, moreSignatures.length) ); - s_forwarder.report(address(s_receiver), report, moreSignatures); + s_forwarder.report(address(s_receiver), report, reportContext, moreSignatures); } function test_RevertWhen_AnySignatureIsInvalid() public { signatures[1] = abi.encode(1234); // invalid signature vm.expectRevert(abi.encodeWithSelector(KeystoneForwarder.InvalidSignature.selector, signatures[1])); - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); } function test_RevertWhen_AnySignerIsInvalid() public { uint256 mockPK = 999; Signer memory maliciousSigner = Signer({mockPrivateKey: mockPK, signerAddress: vm.addr(mockPK)}); - (uint8 v, bytes32 r, bytes32 s) = vm.sign(maliciousSigner.mockPrivateKey, keccak256(report)); - signatures[1] = bytes.concat(r, s, bytes1(v)); + (uint8 v, bytes32 r, bytes32 s) = vm.sign( + maliciousSigner.mockPrivateKey, + keccak256(abi.encodePacked(keccak256(report), reportContext)) + ); + signatures[1] = bytes.concat(r, s, bytes1(v - 27)); vm.expectRevert(abi.encodeWithSelector(KeystoneForwarder.InvalidSigner.selector, maliciousSigner.signerAddress)); - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); } function test_RevertWhen_ReportHasDuplicateSignatures() public { signatures[1] = signatures[0]; // repeat a signature vm.expectRevert(abi.encodeWithSelector(KeystoneForwarder.DuplicateSigner.selector, s_signers[0].signerAddress)); - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); } function test_RevertWhen_ReportAlreadyProcessed() public { - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); bytes32 reportId = keccak256(bytes.concat(bytes20(uint160(address(s_receiver))), executionId)); vm.expectRevert(abi.encodeWithSelector(KeystoneForwarder.ReportAlreadyProcessed.selector, reportId)); - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); } function test_Report_SuccessfulDelivery() public { @@ -123,7 +130,7 @@ contract KeystoneForwarder_ReportTest is BaseTest { vm.expectEmit(address(s_forwarder)); emit ReportProcessed(address(s_receiver), workflowOwner, executionId, true); - s_forwarder.report(address(s_receiver), report, signatures); + s_forwarder.report(address(s_receiver), report, reportContext, signatures); // validate transmitter was recorded address transmitter = s_forwarder.getTransmitter(address(s_receiver), executionId); diff --git a/core/capabilities/targets/write_target.go b/core/capabilities/targets/write_target.go index 6a55499a5a8..23135d11dfe 100644 --- a/core/capabilities/targets/write_target.go +++ b/core/capabilities/targets/write_target.go @@ -107,6 +107,7 @@ func (cap *EvmWrite) Execute(ctx context.Context, request capabilities.Capabilit var inputs struct { Report []byte + Context []byte Signatures [][]byte } if err = signedReport.UnwrapTo(&inputs); err != nil { @@ -127,12 +128,12 @@ func (cap *EvmWrite) Execute(ctx context.Context, request capabilities.Capabilit }() return callback, nil } - cap.lggr.Debugw("WriteTarget non-empty report - attempting to push to txmgr", "request", request, "report", inputs.Report, "signatures", inputs.Signatures) + cap.lggr.Debugw("WriteTarget non-empty report - attempting to push to txmgr", "request", request, "reportLen", len(inputs.Report), "reportContextLen", len(inputs.Context), "nSignatures", len(inputs.Signatures)) // TODO: validate encoded report is prefixed with workflowID and executionID that match the request meta // construct forwarder payload - calldata, err := forwardABI.Pack("report", common.HexToAddress(reqConfig.Address), inputs.Report, inputs.Signatures) + calldata, err := forwardABI.Pack("report", common.HexToAddress(reqConfig.Address), inputs.Report, inputs.Context, inputs.Signatures) if err != nil { return nil, err } diff --git a/core/gethwrappers/keystone/generated/forwarder/forwarder.go b/core/gethwrappers/keystone/generated/forwarder/forwarder.go index fbdd024c64f..531bbef0d9f 100644 --- a/core/gethwrappers/keystone/generated/forwarder/forwarder.go +++ b/core/gethwrappers/keystone/generated/forwarder/forwarder.go @@ -31,8 +31,8 @@ var ( ) var KeystoneForwarderMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"DuplicateSigner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxSigners\",\"type\":\"uint256\"}],\"name\":\"ExcessSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FaultToleranceMustBePositive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"donId\",\"type\":\"uint32\"}],\"name\":\"InvalidDonId\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"expected\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"received\",\"type\":\"uint256\"}],\"name\":\"InvalidSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"reportId\",\"type\":\"bytes32\"}],\"name\":\"ReportAlreadyProcessed\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"OwnershipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"workflowOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"workflowExecutionId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"name\":\"ReportProcessed\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"workflowExecutionId\",\"type\":\"bytes32\"}],\"name\":\"getTransmitter\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"receiverAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes[]\",\"name\":\"signatures\",\"type\":\"bytes[]\"}],\"name\":\"report\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"donId\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b5033806000816100675760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615610097576100978161009f565b505050610148565b336001600160a01b038216036100f75760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161005e565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b61151d806101576000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c806379ba50971161005b57806379ba5097146101175780638da5cb5b1461011f578063c0965dc31461013d578063f2fde38b1461015057600080fd5b8063134a46f014610082578063181f5a7714610097578063390d0b15146100df575b600080fd5b610095610090366004611106565b610163565b005b604080518082018252601781527f4b657973746f6e65466f7277617264657220312e302e30000000000000000000602082015290516100d691906111de565b60405180910390f35b6100f26100ed366004611221565b61057d565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100d6565b61009561060e565b60005473ffffffffffffffffffffffffffffffffffffffff166100f2565b61009561014b36600461124b565b61070b565b61009561015e3660046112fa565b610ded565b60015474010000000000000000000000000000000000000000900460ff16156101b8576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000017905560ff8316600003610234576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f81111561027e576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101829052601f60248201526044015b60405180910390fd5b610289836003611344565b60ff1681116102e7578061029e846003611344565b6102a9906001611367565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260ff166024820152604401610275565b60005b63ffffffff85166000908152600260205260409020600101548110156103885763ffffffff8516600090815260026020526040812060010180548390811061033457610334611380565b600091825260208083209091015463ffffffff891683526002808352604080852073ffffffffffffffffffffffffffffffffffffffff9093168552910190915281205550610381816113af565b90506102ea565b5063ffffffff841660009081526002602052604090206103ac906001018383610ffe565b5060005b8181101561050a5760008383838181106103cc576103cc611380565b90506020020160208101906103e191906112fa565b63ffffffff8716600090815260026020818152604080842073ffffffffffffffffffffffffffffffffffffffff8616855290920190529020549091501561046c576040517fe021c4f200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610275565b610477826001611367565b63ffffffff8716600090815260026020818152604080842073ffffffffffffffffffffffffffffffffffffffff909616808552868401835290842060ff959095169094559081526001938401805494850181558252902090910180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169091179055610503816113af565b90506103b0565b50505063ffffffff91909116600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b6000806105df84846040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084901b1660208201526034810182905260009060540160405160208183030381529060405280519060200120905092915050565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff169150505b92915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461068f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610275565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60015474010000000000000000000000000000000000000000900460ff1615610760576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000017905560588310156107da576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060008061081f88888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e0192505050565b63ffffffff8316600090815260026020526040812054949850929650909450925060ff9091169003610885576040517fea1b312900000000000000000000000000000000000000000000000000000000815263ffffffff84166004820152602401610275565b604080517fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060608c901b1660208083019190915260348083018690528351808403909101815260549092018352815191810191909120600081815260039092529190205473ffffffffffffffffffffffffffffffffffffffff1615610939576040517f1aac3d2900000000000000000000000000000000000000000000000000000000815260048101829052602401610275565b63ffffffff8416600090815260026020526040902054869061095f9060ff166001611367565b60ff16146109ca5763ffffffff841660009081526002602052604090205461098b9060ff166001611367565b6040517fd6022e8e00000000000000000000000000000000000000000000000000000000815260ff909116600482015260248101879052604401610275565b600089896040516109dc9291906113e7565b604051809103902090506109ee611086565b6000805b89811015610c5c576000806000610a608e8e86818110610a1457610a14611380565b9050602002810190610a2691906113f7565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e2692505050565b925092509250600060018883868660405160008152602001604052604051610aa4949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015610ac6573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015163ffffffff8f1660009081526002602081815284832073ffffffffffffffffffffffffffffffffffffffff851684529091019052918220549850925060ff881690039050610b81576040517fbf18af4300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610275565b610b8c60018761145c565b955060008760ff8816601f8110610ba557610ba5611380565b602002015173ffffffffffffffffffffffffffffffffffffffff1614610c0f576040517fe021c4f200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610275565b80878760ff16601f8110610c2557610c25611380565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015250610c5592508391506113af9050565b90506109f2565b5050505060008a905060008173ffffffffffffffffffffffffffffffffffffffff1663ff5a027088868e8e6058908092610c9893929190611475565b6040518563ffffffff1660e01b8152600401610cb7949392919061149f565b600060405180830381600087803b158015610cd157600080fd5b505af1925050508015610ce2575060015b15610ceb575060015b604080518082018252338152821515602080830191825260008781526003909152839020915182549151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff00000000000000000000000000000000000000000090921673ffffffffffffffffffffffffffffffffffffffff91821617919091179091559051869186811691908f16907fdae8e752043eb5fc7e4a6eced57ceaf159548b630125ece9ffc41cfc952c208190610daf90861515815260200190565b60405180910390a45050600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16905550505050505050505050565b610df5610e86565b610dfe81610f09565b50565b602081015160408201516044830151606490930151919360e09190911c929160601c90565b60008060006041845114610e6857836040517f2adfdc3000000000000000000000000000000000000000000000000000000000815260040161027591906111de565b50505060208101516040820151606090920151909260009190911a90565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f07576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610275565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610f88576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610275565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215611076579160200282015b828111156110765781547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84351617825560209092019160019091019061101e565b506110829291506110a5565b5090565b604051806103e00160405280601f906020820280368337509192915050565b5b8082111561108257600081556001016110a6565b60008083601f8401126110cc57600080fd5b50813567ffffffffffffffff8111156110e457600080fd5b6020830191508360208260051b85010111156110ff57600080fd5b9250929050565b6000806000806060858703121561111c57600080fd5b843563ffffffff8116811461113057600080fd5b9350602085013560ff8116811461114657600080fd5b9250604085013567ffffffffffffffff81111561116257600080fd5b61116e878288016110ba565b95989497509550505050565b6000815180845260005b818110156111a057602081850181015186830182015201611184565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006111f1602083018461117a565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461121c57600080fd5b919050565b6000806040838503121561123457600080fd5b61123d836111f8565b946020939093013593505050565b60008060008060006060868803121561126357600080fd5b61126c866111f8565b9450602086013567ffffffffffffffff8082111561128957600080fd5b818801915088601f83011261129d57600080fd5b8135818111156112ac57600080fd5b8960208285010111156112be57600080fd5b6020830196508095505060408801359150808211156112dc57600080fd5b506112e9888289016110ba565b969995985093965092949392505050565b60006020828403121561130c57600080fd5b6111f1826111f8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60ff818116838216029081169081811461136057611360611315565b5092915050565b60ff818116838216019081111561060857610608611315565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036113e0576113e0611315565b5060010190565b8183823760009101908152919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261142c57600080fd5b83018035915067ffffffffffffffff82111561144757600080fd5b6020019150368190038213156110ff57600080fd5b60ff828116828216039081111561060857610608611315565b6000808585111561148557600080fd5b8386111561149257600080fd5b5050820193919092039150565b84815273ffffffffffffffffffffffffffffffffffffffff8416602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101939250505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"DuplicateSigner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxSigners\",\"type\":\"uint256\"}],\"name\":\"ExcessSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FaultToleranceMustBePositive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"donId\",\"type\":\"uint32\"}],\"name\":\"InvalidDonId\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signature\",\"type\":\"bytes\"}],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"expected\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"received\",\"type\":\"uint256\"}],\"name\":\"InvalidSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"signer\",\"type\":\"address\"}],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"reportId\",\"type\":\"bytes32\"}],\"name\":\"ReportAlreadyProcessed\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"OwnershipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"workflowOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"workflowExecutionId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"}],\"name\":\"ReportProcessed\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"workflowExecutionId\",\"type\":\"bytes32\"}],\"name\":\"getTransmitter\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"receiverAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"reportContext\",\"type\":\"bytes\"},{\"internalType\":\"bytes[]\",\"name\":\"signatures\",\"type\":\"bytes[]\"}],\"name\":\"report\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"donId\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b5033806000816100675760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615610097576100978161009f565b505050610148565b336001600160a01b038216036100f75760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161005e565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6115e0806101576000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063390d0b151161005b578063390d0b15146100f257806379ba50971461012a5780638da5cb5b14610132578063f2fde38b1461015057600080fd5b80631128956514610082578063134a46f014610097578063181f5a77146100aa575b600080fd5b6100956100903660046111dc565b610163565b005b6100956100a5366004611287565b6108b5565b604080518082018252601781527f4b657973746f6e65466f7277617264657220312e302e30000000000000000000602082015290516100e9919061135f565b60405180910390f35b610105610100366004611379565b610cca565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100e9565b610095610d5b565b60005473ffffffffffffffffffffffffffffffffffffffff16610105565b61009561015e3660046113a3565b610e58565b60015474010000000000000000000000000000000000000000900460ff16156101b8576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000001790556058851015610232576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000806102778a8a8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e6c92505050565b63ffffffff8316600090815260026020526040812054949850929650909450925060ff90911690036102e2576040517fea1b312900000000000000000000000000000000000000000000000000000000815263ffffffff841660048201526024015b60405180910390fd5b604080517fffffffffffffffffffffffffffffffffffffffff00000000000000000000000060608e901b1660208083019190915260348083018690528351808403909101815260549092018352815191810191909120600081815260039092529190205473ffffffffffffffffffffffffffffffffffffffff1615610396576040517f1aac3d29000000000000000000000000000000000000000000000000000000008152600481018290526024016102d9565b63ffffffff841660009081526002602052604090205486906103bc9060ff1660016113ed565b60ff16146104275763ffffffff84166000908152600260205260409020546103e89060ff1660016113ed565b6040517fd6022e8e00000000000000000000000000000000000000000000000000000000815260ff9091166004820152602481018790526044016102d9565b60008b8b604051610439929190611406565b604051908190038120610452918c908c90602001611416565b604051602081830303815290604052805190602001209050610472611069565b6000805b898110156106e05760008060006104e48e8e8681811061049857610498611430565b90506020028101906104aa919061145f565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610e9192505050565b9194509250905060006001886104fb84601b6113ed565b6040805160008152602081018083529390935260ff90911690820152606081018690526080810185905260a0016020604051602081039080840390855afa15801561054a573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015163ffffffff8f1660009081526002602081815284832073ffffffffffffffffffffffffffffffffffffffff851684529091019052918220549850925060ff881690039050610605576040517fbf18af4300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016102d9565b6106106001876114c4565b955060008760ff8816601f811061062957610629611430565b602002015173ffffffffffffffffffffffffffffffffffffffff1614610693576040517fe021c4f200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016102d9565b80878760ff16601f81106106a9576106a9611430565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152506106d992508391506114dd9050565b9050610476565b5050505060008c73ffffffffffffffffffffffffffffffffffffffff1663ff5a027087858f8f605890809261071793929190611515565b6040518563ffffffff1660e01b8152600401610736949392919061153f565b600060405180830381600087803b15801561075057600080fd5b505af1925050508015610761575060015b1561076a575060015b60405180604001604052803373ffffffffffffffffffffffffffffffffffffffff1681526020018215158152506003600084815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160000160146101000a81548160ff021916908315150217905550905050838373ffffffffffffffffffffffffffffffffffffffff168e73ffffffffffffffffffffffffffffffffffffffff167fdae8e752043eb5fc7e4a6eced57ceaf159548b630125ece9ffc41cfc952c208184604051610876911515815260200190565b60405180910390a45050600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1690555050505050505050505050565b60015474010000000000000000000000000000000000000000900460ff161561090a576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000017905560ff8316600003610986576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8111156109cb576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101829052601f60248201526044016102d9565b6109d68360036115b0565b60ff168111610a3457806109eb8460036115b0565b6109f69060016113ed565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260ff1660248201526044016102d9565b60005b63ffffffff8516600090815260026020526040902060010154811015610ad55763ffffffff85166000908152600260205260408120600101805483908110610a8157610a81611430565b600091825260208083209091015463ffffffff891683526002808352604080852073ffffffffffffffffffffffffffffffffffffffff9093168552910190915281205550610ace816114dd565b9050610a37565b5063ffffffff84166000908152600260205260409020610af9906001018383611088565b5060005b81811015610c57576000838383818110610b1957610b19611430565b9050602002016020810190610b2e91906113a3565b63ffffffff8716600090815260026020818152604080842073ffffffffffffffffffffffffffffffffffffffff86168552909201905290205490915015610bb9576040517fe021c4f200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016102d9565b610bc48260016113ed565b63ffffffff8716600090815260026020818152604080842073ffffffffffffffffffffffffffffffffffffffff909616808552868401835290842060ff959095169094559081526001938401805494850181558252902090910180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169091179055610c50816114dd565b9050610afd565b50505063ffffffff91909116600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff169055565b600080610d2c84846040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084901b1660208201526034810182905260009060540160405160208183030381529060405280519060200120905092915050565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff169150505b92915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610ddc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016102d9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e60610ef1565b610e6981610f74565b50565b602081015160408201516044830151606490930151919360e09190911c929160601c90565b60008060006041845114610ed357836040517f2adfdc300000000000000000000000000000000000000000000000000000000081526004016102d9919061135f565b50505060208101516040820151606090920151909260009190911a90565b60005473ffffffffffffffffffffffffffffffffffffffff163314610f72576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016102d9565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610ff3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016102d9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b604051806103e00160405280601f906020820280368337509192915050565b828054828255906000526020600020908101928215611100579160200282015b828111156111005781547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8435161782556020909201916001909101906110a8565b5061110c929150611110565b5090565b5b8082111561110c5760008155600101611111565b803573ffffffffffffffffffffffffffffffffffffffff8116811461114957600080fd5b919050565b60008083601f84011261116057600080fd5b50813567ffffffffffffffff81111561117857600080fd5b60208301915083602082850101111561119057600080fd5b9250929050565b60008083601f8401126111a957600080fd5b50813567ffffffffffffffff8111156111c157600080fd5b6020830191508360208260051b850101111561119057600080fd5b60008060008060008060006080888a0312156111f757600080fd5b61120088611125565b9650602088013567ffffffffffffffff8082111561121d57600080fd5b6112298b838c0161114e565b909850965060408a013591508082111561124257600080fd5b61124e8b838c0161114e565b909650945060608a013591508082111561126757600080fd5b506112748a828b01611197565b989b979a50959850939692959293505050565b6000806000806060858703121561129d57600080fd5b843563ffffffff811681146112b157600080fd5b9350602085013560ff811681146112c757600080fd5b9250604085013567ffffffffffffffff8111156112e357600080fd5b6112ef87828801611197565b95989497509550505050565b6000815180845260005b8181101561132157602081850181015186830182015201611305565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b60208152600061137260208301846112fb565b9392505050565b6000806040838503121561138c57600080fd5b61139583611125565b946020939093013593505050565b6000602082840312156113b557600080fd5b61137282611125565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60ff8181168382160190811115610d5557610d556113be565b8183823760009101908152919050565b838152818360208301376000910160200190815292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261149457600080fd5b83018035915067ffffffffffffffff8211156114af57600080fd5b60200191503681900382131561119057600080fd5b60ff8281168282160390811115610d5557610d556113be565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361150e5761150e6113be565b5060010190565b6000808585111561152557600080fd5b8386111561153257600080fd5b5050820193919092039150565b84815273ffffffffffffffffffffffffffffffffffffffff8416602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60ff81811683821602908116908181146115cc576115cc6113be565b509291505056fea164736f6c6343000813000a", } var KeystoneForwarderABI = KeystoneForwarderMetaData.ABI @@ -249,16 +249,16 @@ func (_KeystoneForwarder *KeystoneForwarderTransactorSession) AcceptOwnership() return _KeystoneForwarder.Contract.AcceptOwnership(&_KeystoneForwarder.TransactOpts) } -func (_KeystoneForwarder *KeystoneForwarderTransactor) Report(opts *bind.TransactOpts, receiverAddress common.Address, rawReport []byte, signatures [][]byte) (*types.Transaction, error) { - return _KeystoneForwarder.contract.Transact(opts, "report", receiverAddress, rawReport, signatures) +func (_KeystoneForwarder *KeystoneForwarderTransactor) Report(opts *bind.TransactOpts, receiverAddress common.Address, rawReport []byte, reportContext []byte, signatures [][]byte) (*types.Transaction, error) { + return _KeystoneForwarder.contract.Transact(opts, "report", receiverAddress, rawReport, reportContext, signatures) } -func (_KeystoneForwarder *KeystoneForwarderSession) Report(receiverAddress common.Address, rawReport []byte, signatures [][]byte) (*types.Transaction, error) { - return _KeystoneForwarder.Contract.Report(&_KeystoneForwarder.TransactOpts, receiverAddress, rawReport, signatures) +func (_KeystoneForwarder *KeystoneForwarderSession) Report(receiverAddress common.Address, rawReport []byte, reportContext []byte, signatures [][]byte) (*types.Transaction, error) { + return _KeystoneForwarder.Contract.Report(&_KeystoneForwarder.TransactOpts, receiverAddress, rawReport, reportContext, signatures) } -func (_KeystoneForwarder *KeystoneForwarderTransactorSession) Report(receiverAddress common.Address, rawReport []byte, signatures [][]byte) (*types.Transaction, error) { - return _KeystoneForwarder.Contract.Report(&_KeystoneForwarder.TransactOpts, receiverAddress, rawReport, signatures) +func (_KeystoneForwarder *KeystoneForwarderTransactorSession) Report(receiverAddress common.Address, rawReport []byte, reportContext []byte, signatures [][]byte) (*types.Transaction, error) { + return _KeystoneForwarder.Contract.Report(&_KeystoneForwarder.TransactOpts, receiverAddress, rawReport, reportContext, signatures) } func (_KeystoneForwarder *KeystoneForwarderTransactor) SetConfig(opts *bind.TransactOpts, donId uint32, f uint8, signers []common.Address) (*types.Transaction, error) { @@ -742,7 +742,7 @@ type KeystoneForwarderInterface interface { AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - Report(opts *bind.TransactOpts, receiverAddress common.Address, rawReport []byte, signatures [][]byte) (*types.Transaction, error) + Report(opts *bind.TransactOpts, receiverAddress common.Address, rawReport []byte, reportContext []byte, signatures [][]byte) (*types.Transaction, error) SetConfig(opts *bind.TransactOpts, donId uint32, f uint8, signers []common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/keystone/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/keystone/generation/generated-wrapper-dependency-versions-do-not-edit.txt index c58901795ce..8eebdbf4a78 100644 --- a/core/gethwrappers/keystone/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/keystone/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,4 +1,4 @@ GETH_VERSION: 1.13.8 -forwarder: ../../../contracts/solc/v0.8.19/KeystoneForwarder/KeystoneForwarder.abi ../../../contracts/solc/v0.8.19/KeystoneForwarder/KeystoneForwarder.bin ed9164cfe4619dff824b11df46b66f4c6834b2ca072923f10d9ebc57ce508ed8 +forwarder: ../../../contracts/solc/v0.8.19/KeystoneForwarder/KeystoneForwarder.abi ../../../contracts/solc/v0.8.19/KeystoneForwarder/KeystoneForwarder.bin 2407c8de12f430c9907f5fdc7a93398c0085c2800b88c11344b10f849cd854a7 keystone_capability_registry: ../../../contracts/solc/v0.8.19/CapabilityRegistry/CapabilityRegistry.abi ../../../contracts/solc/v0.8.19/CapabilityRegistry/CapabilityRegistry.bin 0a79d0eba13fd4a4b83d7618bb181c21c42222f3cc6c5a90a09302f685555033 ocr3_capability: ../../../contracts/solc/v0.8.19/OCR3Capability/OCR3Capability.abi ../../../contracts/solc/v0.8.19/OCR3Capability/OCR3Capability.bin 9dcbdf55bd5729ba266148da3f17733eb592c871c2108ccca546618628fd9ad2 diff --git a/core/scripts/go.mod b/core/scripts/go.mod index f9537449089..205cb83eec7 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -21,7 +21,7 @@ require ( github.com/prometheus/client_golang v1.17.0 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink-automation v1.0.3 - github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e + github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 github.com/smartcontractkit/chainlink-vrf v0.0.0-20240222010609-cd67d123c772 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20240419185742-fd3cab206b2c diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 8788867bc8f..ba0f064315e 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1185,8 +1185,8 @@ github.com/smartcontractkit/chain-selectors v1.0.10 h1:t9kJeE6B6G+hKD0GYR4kGJSCq github.com/smartcontractkit/chain-selectors v1.0.10/go.mod h1:d4Hi+E1zqjy9HqMkjBE5q1vcG9VGgxf5VxiRHfzi2kE= github.com/smartcontractkit/chainlink-automation v1.0.3 h1:h/ijT0NiyV06VxYVgcNfsE3+8OEzT3Q0Z9au0z1BPWs= github.com/smartcontractkit/chainlink-automation v1.0.3/go.mod h1:RjboV0Qd7YP+To+OrzHGXaxUxoSONveCoAK2TQ1INLU= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e h1:+lMjCyABWYAEr0ueTKheYHe9YbUx27UP+zpUOi+7Jz4= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 h1:owNVqkBje7u+q7eATcvEVfaEsGC3nPladp6Gu19+W10= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d h1:5tgMC5Gi2UAOKZ+m28W8ubjLeR0pQCAcrz6eQ0rW510= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d/go.mod h1:0UNuO3nDt9MFsZPaHJBEUolxVkN0iC69j1ccDp95e8k= github.com/smartcontractkit/chainlink-data-streams v0.0.0-20240220203239-09be0ea34540 h1:xFSv8561jsLtF6gYZr/zW2z5qUUAkcFkApin2mnbYTo= diff --git a/core/services/relay/evm/cap_encoder.go b/core/services/relay/evm/cap_encoder.go index e0e3a2cf0f5..08dc9786eb2 100644 --- a/core/services/relay/evm/cap_encoder.go +++ b/core/services/relay/evm/cap_encoder.go @@ -104,7 +104,7 @@ func extractIDs(input map[string]any) ([]byte, []byte, []byte, []byte, error) { // TODO: source donID and workflowOwner from somewhere donID := []byte{0, 1, 2, 3} - workflowOwner := make([]byte, 32) + workflowOwner := make([]byte, 20) executionID, err := decodeID(input, consensustypes.ExecutionIDFieldName, idLen) if err != nil { diff --git a/core/services/relay/evm/cap_encoder_test.go b/core/services/relay/evm/cap_encoder_test.go index 8c56fb9075a..a57ac93b4f3 100644 --- a/core/services/relay/evm/cap_encoder_test.go +++ b/core/services/relay/evm/cap_encoder_test.go @@ -18,11 +18,10 @@ var ( reportA = []byte{0x01, 0x02, 0x03} reportB = []byte{0xaa, 0xbb, 0xcc, 0xdd} - // hex encoded 32 byte strings workflowID = "15c631d295ef5e32deb99a10ee6804bc4af1385568f9b3363f6552ac6dbb2cef" donID = "00010203" executionID = "8d4e66421db647dd916d3ec28d56188c8d7dae5f808e03d03339ed2562f13bb0" - workflowOwnerID = "0000000000000000000000000000000000000000000000000000000000000000" + workflowOwnerID = "0000000000000000000000000000000000000000" invalidID = "not_valid" wrongLength = "8d4e66" diff --git a/go.mod b/go.mod index 58cf2d797df..b583c903f8f 100644 --- a/go.mod +++ b/go.mod @@ -72,7 +72,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chain-selectors v1.0.10 github.com/smartcontractkit/chainlink-automation v1.0.3 - github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e + github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d github.com/smartcontractkit/chainlink-data-streams v0.0.0-20240220203239-09be0ea34540 github.com/smartcontractkit/chainlink-feeds v0.0.0-20240522213638-159fb2d99917 diff --git a/go.sum b/go.sum index 2085e3c3fd6..f0323b1e29b 100644 --- a/go.sum +++ b/go.sum @@ -1171,8 +1171,8 @@ github.com/smartcontractkit/chain-selectors v1.0.10 h1:t9kJeE6B6G+hKD0GYR4kGJSCq github.com/smartcontractkit/chain-selectors v1.0.10/go.mod h1:d4Hi+E1zqjy9HqMkjBE5q1vcG9VGgxf5VxiRHfzi2kE= github.com/smartcontractkit/chainlink-automation v1.0.3 h1:h/ijT0NiyV06VxYVgcNfsE3+8OEzT3Q0Z9au0z1BPWs= github.com/smartcontractkit/chainlink-automation v1.0.3/go.mod h1:RjboV0Qd7YP+To+OrzHGXaxUxoSONveCoAK2TQ1INLU= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e h1:+lMjCyABWYAEr0ueTKheYHe9YbUx27UP+zpUOi+7Jz4= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 h1:owNVqkBje7u+q7eATcvEVfaEsGC3nPladp6Gu19+W10= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d h1:5tgMC5Gi2UAOKZ+m28W8ubjLeR0pQCAcrz6eQ0rW510= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d/go.mod h1:0UNuO3nDt9MFsZPaHJBEUolxVkN0iC69j1ccDp95e8k= github.com/smartcontractkit/chainlink-data-streams v0.0.0-20240220203239-09be0ea34540 h1:xFSv8561jsLtF6gYZr/zW2z5qUUAkcFkApin2mnbYTo= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 3d6814244c9..0afe633a930 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -27,7 +27,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-automation v1.0.3 - github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e + github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 github.com/smartcontractkit/chainlink-testing-framework v1.28.17 github.com/smartcontractkit/chainlink-vrf v0.0.0-20231120191722-fef03814f868 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 4340728e653..9dc474889bd 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1512,8 +1512,8 @@ github.com/smartcontractkit/chain-selectors v1.0.10 h1:t9kJeE6B6G+hKD0GYR4kGJSCq github.com/smartcontractkit/chain-selectors v1.0.10/go.mod h1:d4Hi+E1zqjy9HqMkjBE5q1vcG9VGgxf5VxiRHfzi2kE= github.com/smartcontractkit/chainlink-automation v1.0.3 h1:h/ijT0NiyV06VxYVgcNfsE3+8OEzT3Q0Z9au0z1BPWs= github.com/smartcontractkit/chainlink-automation v1.0.3/go.mod h1:RjboV0Qd7YP+To+OrzHGXaxUxoSONveCoAK2TQ1INLU= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e h1:+lMjCyABWYAEr0ueTKheYHe9YbUx27UP+zpUOi+7Jz4= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 h1:owNVqkBje7u+q7eATcvEVfaEsGC3nPladp6Gu19+W10= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d h1:5tgMC5Gi2UAOKZ+m28W8ubjLeR0pQCAcrz6eQ0rW510= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d/go.mod h1:0UNuO3nDt9MFsZPaHJBEUolxVkN0iC69j1ccDp95e8k= github.com/smartcontractkit/chainlink-data-streams v0.0.0-20240220203239-09be0ea34540 h1:xFSv8561jsLtF6gYZr/zW2z5qUUAkcFkApin2mnbYTo= diff --git a/integration-tests/load/go.mod b/integration-tests/load/go.mod index 5762df219e4..7b1ba024524 100644 --- a/integration-tests/load/go.mod +++ b/integration-tests/load/go.mod @@ -16,7 +16,7 @@ require ( github.com/rs/zerolog v1.30.0 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-automation v1.0.3 - github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e + github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 github.com/smartcontractkit/chainlink-testing-framework v1.28.17 github.com/smartcontractkit/chainlink/integration-tests v0.0.0-20240214231432-4ad5eb95178c github.com/smartcontractkit/chainlink/v2 v2.9.0-beta0.0.20240216210048-da02459ddad8 diff --git a/integration-tests/load/go.sum b/integration-tests/load/go.sum index c0ca0e3049c..f9062a6c4f7 100644 --- a/integration-tests/load/go.sum +++ b/integration-tests/load/go.sum @@ -1502,8 +1502,8 @@ github.com/smartcontractkit/chain-selectors v1.0.10 h1:t9kJeE6B6G+hKD0GYR4kGJSCq github.com/smartcontractkit/chain-selectors v1.0.10/go.mod h1:d4Hi+E1zqjy9HqMkjBE5q1vcG9VGgxf5VxiRHfzi2kE= github.com/smartcontractkit/chainlink-automation v1.0.3 h1:h/ijT0NiyV06VxYVgcNfsE3+8OEzT3Q0Z9au0z1BPWs= github.com/smartcontractkit/chainlink-automation v1.0.3/go.mod h1:RjboV0Qd7YP+To+OrzHGXaxUxoSONveCoAK2TQ1INLU= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e h1:+lMjCyABWYAEr0ueTKheYHe9YbUx27UP+zpUOi+7Jz4= -github.com/smartcontractkit/chainlink-common v0.1.7-0.20240528165711-19b9064a1d7e/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9 h1:owNVqkBje7u+q7eATcvEVfaEsGC3nPladp6Gu19+W10= +github.com/smartcontractkit/chainlink-common v0.1.7-0.20240530140143-638cade4f7f9/go.mod h1:DUZccDEW98n+J1mhdWGO7wr/Njad9p9Fzks839JN7Rs= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d h1:5tgMC5Gi2UAOKZ+m28W8ubjLeR0pQCAcrz6eQ0rW510= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20240524214833-c362c2ebbd2d/go.mod h1:0UNuO3nDt9MFsZPaHJBEUolxVkN0iC69j1ccDp95e8k= github.com/smartcontractkit/chainlink-data-streams v0.0.0-20240220203239-09be0ea34540 h1:xFSv8561jsLtF6gYZr/zW2z5qUUAkcFkApin2mnbYTo=